Skip to content

Commit e583d5f

Browse files
committed
Fix encoding for ldap results
1 parent 15f84fd commit e583d5f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

nxc/parsers/ldap_results.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ def parse_result_attributes(ldap_response):
88
continue
99
attribute_map = {}
1010
for attribute in entry["attributes"]:
11-
val = [str(val) for val in attribute["vals"].components]
11+
val = [str(val).encode(val.encoding).decode("utf-8") for val in attribute["vals"].components]
1212
attribute_map[str(attribute["type"])] = val if len(val) > 1 else val[0]
1313
parsed_response.append(attribute_map)
1414
return parsed_response

0 commit comments

Comments
 (0)