Last active
May 23, 2019 06:58
-
-
Save lilongen/d9141728891131625d2d3b381973c427 to your computer and use it in GitHub Desktop.
hue+ldap.auth+issue
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File "/opt/cloudera/parcels/CDH-5.14.0-1.cdh5.14.0.p0.24/lib/hue/build/env/lib/python2.7/site-packages/django_auth_ldap-1.2.0-py2.7.egg/django_auth_ldap/config.py", line 159, in execute | |
filterstr = self.filterstr % filterargs | |
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe7 in position 73: ordinal not in range(128) | |
solution/ | |
file: | |
/opt/cloudera/parcels/CDH-5.14.0-1.cdh5.14.0.p0.24/lib/hue/build/env/lib/python2.7/site-packages/django_auth_ldap-1.2.0-py2.7.egg/django_auth_ldap/config.py | |
line 155: | |
filterstr = self.filterstr % filterargs | |
to | |
# added for workaround hue ldap login issue | |
# 2019/05/23, lile | |
for k, v in filterargs.items(): | |
if isinstance(v, unicode): | |
filterargs[k] = v.encode('utf-8') | |
# end | |
filterstr = self.filterstr % filterargs | |
line 217-219: commented | |
#logger.debug(u"search_s('%s', %d, '%s') returned %d objects: %s" % | |
# (self.base_dn, self.scope, self.filterstr, len(result_dns), | |
# "; ".join(result_dns))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment