OTP Encryption should use XOR

Bug #901058 reported by aj00200
258
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Anonplus
Fix Released
Wishlist
Vomun Security Team

Bug Description

The OTP encryption module is currently using addition and then modulo division to preform encryption but XOR encryption would be much better since it works at the bit level and it would probably be faster.

XOR can be preformed by PyCrypto (which is probably fast, at least if the faster math stuff is available). Otherwise, the following code works, however is significantly slower than XOR in PyCrypto.

"".join(chr(ord(p) ^ ord(o)) for plain[i],otp[i] in range(len(plain))

Tags: encryption

Related branches

aj00200 (aj00200)
visibility: private → public
al1ce (al1ce)
description: updated
aj00200 (aj00200)
Changed in anonplus:
assignee: aj00200 (aj00200) → Vomun Security Team (vomun-security)
milestone: none → build-8
aj00200 (aj00200)
Changed in anonplus:
milestone: build-8 → build-7
aj00200 (aj00200)
Changed in anonplus:
status: Triaged → Fix Committed
aj00200 (aj00200)
Changed in anonplus:
milestone: build-7 → r212
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public Security information  
Everyone can see this security related information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.