From: Andreas Schneider Date: Tue, 30 Jan 2018 17:09:00 +0000 (+0100) Subject: python: Convert base64 encoded password to utf-8 X-Git-Tag: tevent-0.9.36~105 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a45e70bf47cb4b48f69a237298e143f574bf58bb;p=thirdparty%2Fsamba.git python: Convert base64 encoded password to utf-8 Pair-Programmed-With: Alexander Bokovoy Signed-off-by: Andreas Schneider Signed-off-by: Alexander Bokovoy Reviewed-by: Douglas Bagnall Reviewed-by: Andrew Bartlett --- diff --git a/python/samba/samdb.py b/python/samba/samdb.py index 7f52a5e56f8..abc7e188853 100644 --- a/python/samba/samdb.py +++ b/python/samba/samdb.py @@ -515,7 +515,7 @@ dn: %s changetype: modify replace: unicodePwd unicodePwd:: %s -""" % (user_dn, base64.b64encode(pw)) +""" % (user_dn, base64.b64encode(pw).decode('utf-8')) self.modify_ldif(setpw)