summaryrefslogtreecommitdiff
path: root/python/samba/upgradehelpers.py
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2016-08-23 12:40:24 +0200
committerRalph Boehme <slow@samba.org>2017-02-21 16:09:22 +0100
commitea57a204a1f6b4999e5347c1edb5753bed933fba (patch)
treec48cac1edabb730478bd304bad3ad28e53391618 /python/samba/upgradehelpers.py
parentf04e09e1968c40483b8dc2f92b9c15bce0b0b55a (diff)
downloadsamba-ea57a204a1f6b4999e5347c1edb5753bed933fba.tar.gz
samba-tool:provision: use generate_random_machine_password() for machine passwords
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12262 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org>
Diffstat (limited to 'python/samba/upgradehelpers.py')
-rw-r--r--python/samba/upgradehelpers.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/python/samba/upgradehelpers.py b/python/samba/upgradehelpers.py
index 9b2c1c233aa..99ffe28c9b5 100644
--- a/python/samba/upgradehelpers.py
+++ b/python/samba/upgradehelpers.py
@@ -573,7 +573,7 @@ def update_machine_account_password(samdb, secrets_ldb, names):
assert(len(res) == 1)
msg = ldb.Message(res[0].dn)
- machinepass = samba.generate_random_password(128, 255)
+ machinepass = samba.generate_random_machine_password(128, 255)
mputf16 = machinepass.encode('utf-16-le')
msg["clearTextPassword"] = ldb.MessageElement(mputf16,
ldb.FLAG_MOD_REPLACE,
@@ -648,7 +648,7 @@ def update_krbtgt_account_password(samdb, names):
assert(len(res) == 1)
msg = ldb.Message(res[0].dn)
- machinepass = samba.generate_random_password(128, 255)
+ machinepass = samba.generate_random_machine_password(128, 255)
mputf16 = machinepass.encode('utf-16-le')
msg["clearTextPassword"] = ldb.MessageElement(mputf16,
ldb.FLAG_MOD_REPLACE,