Commit 711bc184 authored by ORD's avatar ORD Committed by GitHub

Merge pull request #216 from hunterjackson/master

changed the function bytes to the function encode for python2 compatibility
parents e66350c6 e519bd29
......@@ -425,7 +425,7 @@ class Client(object):
pubkey = uacrypto.x509_from_der(self.security_policy.server_certificate).public_key()
# see specs part 4, 7.36.3: if the token is encrypted, password
# shall be converted to UTF-8 and serialized with server nonce
passwd = bytes(password, "utf8")
passwd = password.encode("utf8")
if self._server_nonce is not None:
passwd += self._server_nonce
etoken = ua.pack_bytes(passwd)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment