Пример #1
0
 def te_NetrLogonGetTimeServiceParentDomain(self):
     dce, rpctransport = self.connect()
     request = nrpc.NetrLogonGetTimeServiceParentDomain()
     request['ServerName'] = self.domain + '\x00'
     try:
         resp = dce.request(request)
         resp.dump()
     except Exception as e:
         if str(e).find('rpc_s_access_denied') < 0:
             raise
Пример #2
0
    def test_NetrLogonGetTimeServiceParentDomain(self):
        dce, rpctransport = self.connect()
        request = nrpc.NetrLogonGetTimeServiceParentDomain()
        request['ServerName'] = self.serverName + '\x00'

        try:
            dce.request(request)
        except DCERPCException as e:
            # ERROR_NO_SUCH_DOMAIN: The DC is at the root of the forest
            if str(e).find('rpc_s_access_denied') < 0 and str(e).find(
                    'ERROR_NO_SUCH_DOMAIN') < 0:
                raise