Created
February 13, 2017 07:17
-
-
Save JFreegman/7dbd3de96b8af435c75aca094c7cafe8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
key = 'kw6PZq3Zd;ekR[_1' | |
ret = '' | |
for i, ch in enumerate(key): | |
ecx = i + 1 | |
edx = 0x66666667 | |
eax = ecx | |
eax = edx * eax | |
eax = eax & 0xffffffff | |
edx = eax >> 32 | |
edx >>= 3 | |
eax = ecx | |
eax >>= 0x1f | |
edx -= eax | |
eax = edx | |
eax <<= 2 | |
eax += edx | |
eax <<= 2 | |
edx = ecx | |
edx -= eax | |
eax = edx | |
print eax | |
eax ^= ord(ch) | |
ret += chr(eax) | |
print ret | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment