This challenge done on big endian or little endian machine?
or to be more specific..
(txt -> txt[i + 3]) ^ k
would txt correspond to the least significant byte of k or the most?
Didatic Feedback Cipher Long 2
-
- Posts: 144
- Joined: Fri Mar 28, 2008 11:29 pm
- Location: #hacker.org on Freenode
m!nus wrote:k = {unknown 4-byte value}
x = {unknown 4-byte value}
for (i = 0; i < len(txt); i += 4)
c = (txt -> txt[i + 3]) ^ k
print c
k = (c + x) % 0x100000000 // => mod to 1 byte length
wouldn't be the c in the second iteration be 3 plain bytes and one XORed? seems strange to me
Maybe you are dividing instead of modding.