]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
upgradehelpers.py: let update_machine_account_password() use 120 character passwords
authorStefan Metzmacher <metze@samba.org>
Mon, 21 Feb 2022 14:22:06 +0000 (15:22 +0100)
committerJule Anger <janger@samba.org>
Mon, 7 Mar 2022 10:12:26 +0000 (10:12 +0000)
We already changed provision to use 120 character passwords with commit
609ca657652862fd9c81fd11f818efb74f72ff55.

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 6bb7c0f24918329804b7f4fb71908e8fab99e266)

python/samba/upgradehelpers.py

index 69f6e3675e8e1f67586db1696633a08e06bd2eac..ee71b2972bc2579ca56579cbcdc04d0cb02c6dbc 100644 (file)
@@ -584,7 +584,7 @@ def update_machine_account_password(samdb, secrets_ldb, names):
         assert(len(res) == 1)
 
         msg = ldb.Message(res[0].dn)
-        machinepass = samba.generate_random_machine_password(128, 255)
+        machinepass = samba.generate_random_machine_password(120, 120)
         mputf16 = machinepass.encode('utf-16-le')
         msg["clearTextPassword"] = ldb.MessageElement(mputf16,
                                                       ldb.FLAG_MOD_REPLACE,