1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-26 10:04:02 +03:00

samba-tool user: Consistently return a tuple

We would get an error when get_userPassword_hash() returned None, as
get_virtual_crypt_value() would try to unpack the result as a 2-element
tuple.

Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
Joseph Sutton 2022-04-11 11:50:53 +12:00 committed by Andrew Bartlett
parent c3b2dae027
commit f85f6f89f1

View File

@ -1478,7 +1478,7 @@ class GetPasswordCommand(Command):
# the user password hashes. This indicates that password has been
# changed without updating the supplemental credentials.
if unicodePwd != bytearray(up.current_nt_hash.hash):
return None
return None, None
scheme_prefix = "$%d$" % algorithm
prefix = scheme_prefix