1
0
mirror of https://github.com/samba-team/samba.git synced 2025-08-02 00:22:11 +03:00

classicupgrade: fix a a bytes-like object is required, not 'str' error

BUG: https://bugzilla.samba.org/show_bug.cgi?id=14136

Signed-off-by: Bjoern Jacke <bjacke@samba.org>
Reviewed-by: Björn Baumbach <bb@samba.org>

Autobuild-User(master): Björn Jacke <bjacke@samba.org>
Autobuild-Date(master): Mon Sep 23 12:58:20 UTC 2019 on sn-devel-184
This commit is contained in:
Björn Jacke
2019-09-21 13:24:59 +02:00
committed by Bjoern Jacke
parent ec4c597552
commit 465e518d6c

View File

@ -474,7 +474,7 @@ def upgrade_from_samba3(samba3, logger, targetdir, session_info=None,
ldappass = secrets_db.get_ldap_bind_pw(ldapuser)
if ldappass is None:
raise ProvisioningError("ldapsam passdb backend detected but no LDAP Bind PW found in secrets.tdb for user %s. Please point this tool at the secrets.tdb that was used by the previous installation.")
ldappass = ldappass.strip('\x00')
ldappass = ldappass.decode('utf-8').strip('\x00')
ldap = True
else:
ldapuser = None