# an authenticator
def test_client_authenticator(self):
c = self.get_netlogon_connection()
- (authenticator, subsequent) = self.get_authenticator(c)
+ (authenticator, subsequent) = self.get_authenticator()
self.do_NetrLogonSamLogonWithFlags(c, authenticator, subsequent)
- (authenticator, subsequent) = self.get_authenticator(c)
+ (authenticator, subsequent) = self.get_authenticator()
self.do_NetrLogonGetDomainInfo(c, authenticator, subsequent)
- (authenticator, subsequent) = self.get_authenticator(c)
+ (authenticator, subsequent) = self.get_authenticator()
self.do_NetrLogonGetDomainInfo(c, authenticator, subsequent)
- (authenticator, subsequent) = self.get_authenticator(c)
+ (authenticator, subsequent) = self.get_authenticator()
self.do_NetrLogonGetDomainInfo(c, authenticator, subsequent)
# Test using LogonGetDomainInfo to update dNSHostName to an allowed value.
def test_set_dns_hostname_valid(self):
c = self.get_netlogon_connection()
- authenticator, subsequent = self.get_authenticator(c)
+ authenticator, subsequent = self.get_authenticator()
domain_hostname = self.ldb.domain_dns_name()
# when we are denied the right to do so.
def test_set_dns_hostname_valid_denied(self):
c = self.get_netlogon_connection()
- authenticator, subsequent = self.get_authenticator(c)
+ authenticator, subsequent = self.get_authenticator()
res = self.ldb.search(self.machine_dn,
scope=ldb.SCOPE_BASE,
# invalid value, even with Validated Write.
def test_set_dns_hostname_invalid_validated_write(self):
c = self.get_netlogon_connection()
- authenticator, subsequent = self.get_authenticator(c)
+ authenticator, subsequent = self.get_authenticator()
res = self.ldb.search(self.machine_dn,
scope=ldb.SCOPE_BASE,
# invalid value, even with Write Property.
def test_set_dns_hostname_invalid_write_property(self):
c = self.get_netlogon_connection()
- authenticator, subsequent = self.get_authenticator(c)
+ authenticator, subsequent = self.get_authenticator()
res = self.ldb.search(self.machine_dn,
scope=ldb.SCOPE_BASE,
# machine name.
def test_set_dns_hostname_to_machine_name(self):
c = self.get_netlogon_connection()
- authenticator, subsequent = self.get_authenticator(c)
+ authenticator, subsequent = self.get_authenticator()
new_dns_hostname = self.machine_name.encode('utf-8')
# suffix.
def test_set_dns_hostname_invalid_suffix(self):
c = self.get_netlogon_connection()
- authenticator, subsequent = self.get_authenticator(c)
+ authenticator, subsequent = self.get_authenticator()
domain_hostname = self.ldb.domain_dns_name()
# update, but other attributes are still updated.
def test_set_dns_hostname_with_flag(self):
c = self.get_netlogon_connection()
- authenticator, subsequent = self.get_authenticator(c)
+ authenticator, subsequent = self.get_authenticator()
domain_hostname = self.ldb.domain_dns_name()
def do_Netr_ServerPasswordSet2(self):
c = self.get_netlogon_connection()
- (authenticator, subsequent) = self.get_authenticator(c)
+ (authenticator, subsequent) = self.get_authenticator()
PWD_LEN = 32
DATA_LEN = 512
newpass = samba.generate_random_password(PWD_LEN, PWD_LEN)
#
# Get the authenticator from the machine creds.
- def get_authenticator(self, c):
+ def get_authenticator(self):
auth = self.machine_creds.new_client_authenticator()
current = netr_Authenticator()
current.cred.data = [x if isinstance(x, int) else ord(x) for x in auth["credential"]]