commit 23ab3005664b951af6135f18472cbccb178fc988
Author: Paras Chetal <[email protected]>
Date: Sat Mar 4 14:33:50 2017 -0800
Fix Python3 bytes type issue using Cryptography.
Signed-off-by: Patrick O'Doherty <[email protected]>
---
stem/descriptor/hidden_service_descriptor.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/stem/descriptor/hidden_service_descriptor.py
b/stem/descriptor/hidden_service_descriptor.py
index ce3a134..dc42286 100644
--- a/stem/descriptor/hidden_service_descriptor.py
+++ b/stem/descriptor/hidden_service_descriptor.py
@@ -326,7 +326,7 @@ class HiddenServiceDescriptor(Descriptor):
# try decrypting the session key
- cipher = Cipher(algorithms.AES(authentication_cookie), modes.CTR('\x00'
* len(iv)), default_backend())
+ cipher = Cipher(algorithms.AES(authentication_cookie),
modes.CTR(stem.util.str_tools._to_bytes('\x00' * len(iv))), default_backend())
decryptor = cipher.decryptor()
session_key = decryptor.update(encrypted_session_key) +
decryptor.finalize()
_______________________________________________
tor-commits mailing list
[email protected]
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits