mirror of
https://github.com/samba-team/samba.git
synced 2025-03-27 22:50:26 +03:00
selftest: fix failing user setpassword test
A side effect of being able to generate at read time unicodePwd for a gMSA is that we can also generate the unicodePwd from a virtualSambaGPG password. Signed-off-by: Rob van der Linde <rob@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
This commit is contained in:
parent
8b67a86584
commit
562bde91b4
@ -324,7 +324,7 @@ class UserCmdTestCase(SambaToolCmdTest):
|
||||
"syncpasswords --no-wait: 'sAMAccountName': %s out[%s]" % (user["name"], out))
|
||||
self.assertMatch(out, "# unicodePwd::: REDACTED SECRET ATTRIBUTE",
|
||||
"getpassword '# unicodePwd::: REDACTED SECRET ATTRIBUTE': out[%s]" % out)
|
||||
if expect_nt_hash:
|
||||
if expect_nt_hash or "virtualSambaGPG:: " in out:
|
||||
self.assertMatch(out, "unicodePwd:: %s" % unicodePwd,
|
||||
"getpassword unicodePwd: out[%s]" % out)
|
||||
else:
|
||||
@ -349,7 +349,7 @@ class UserCmdTestCase(SambaToolCmdTest):
|
||||
self.assertEqual(err, "Got password OK\n", "getpassword without url")
|
||||
self.assertMatch(out, "sAMAccountName: %s" % (user["name"]),
|
||||
"getpassword: 'sAMAccountName': %s out[%s]" % (user["name"], out))
|
||||
if expect_nt_hash:
|
||||
if expect_nt_hash or "virtualSambaGPG:: " in out:
|
||||
self.assertMatch(out, "unicodePwd:: %s" % unicodePwd,
|
||||
"getpassword unicodePwd: out[%s]" % out)
|
||||
else:
|
||||
|
@ -1 +0,0 @@
|
||||
^samba.tests.samba_tool.user.samba.tests.samba_tool.user.UserCmdTestCase.test_setpassword\(ad_dc_no_ntlm
|
Loading…
x
Reference in New Issue
Block a user