mirror of
https://github.com/samba-team/samba.git
synced 2025-02-12 21:58:10 +03:00
upgradehelpers.py: add a comment to update_krbtgt_account_password()
The backend generates its own random krbtgt password values. BUG: https://bugzilla.samba.org/show_bug.cgi?id=14984 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org> (cherry picked from commit ad0b5561b492dfa28acfc9604b2358bb8b490703)
This commit is contained in:
parent
fcd3dc4e44
commit
98714cc235
@ -660,9 +660,12 @@ def update_krbtgt_account_password(samdb):
|
||||
assert(len(res) == 1)
|
||||
|
||||
msg = ldb.Message(res[0].dn)
|
||||
machinepass = samba.generate_random_machine_password(128, 255)
|
||||
mputf16 = machinepass.encode('utf-16-le')
|
||||
msg["clearTextPassword"] = ldb.MessageElement(mputf16,
|
||||
# Note that the machinepass value is ignored
|
||||
# as the backend (password_hash.c) will generate its
|
||||
# own random values for the krbtgt keys
|
||||
krbtgtpass = samba.generate_random_machine_password(128, 255)
|
||||
kputf16 = krbtgtpass.encode('utf-16-le')
|
||||
msg["clearTextPassword"] = ldb.MessageElement(kputf16,
|
||||
ldb.FLAG_MOD_REPLACE,
|
||||
"clearTextPassword")
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user