We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7aadbc5 commit bcb5977Copy full SHA for bcb5977
mautrix/crypto/ssss/util.py
@@ -67,7 +67,7 @@ def prepare_aes(key: bytes, iv: str | bytes) -> AES:
67
iv = unpaddedbase64.decode_base64(iv)
68
# initial_value = struct.unpack(">Q", iv[8:])[0]
69
# counter = Counter.new(64, prefix=iv[:8], initial_value=initial_value)
70
- counter = Counter.new(128, initial_value=int.from_bytes(iv))
+ counter = Counter.new(128, initial_value=int.from_bytes(iv, byteorder="big"))
71
return AES.new(key=key, mode=AES.MODE_CTR, counter=counter)
72
73
0 commit comments