Author 
Message 
MerickOWA
Joined: 07 Apr 2008 Posts: 182 Location: HkRkoz al KuwaiT 2019 HaCkEr 101 

Didactic XOR Cipher 3 

Having a bit of confusion understanding the 'x' parameter.
Is this a constant? Or does this change? Or is this question part of the challenge?
Edit: I've come to the conclusion that either 'x' isn't constant or theres more to the challenge than it states


Thu Oct 09, 2008 3:33 pm 


adum
Joined: 19 Apr 2007 Posts: 390




'x' is a constant. it is 'b' that changes after each enciphered byte. i'll try to think of a better way to explain this one. since it has been solved, at least i know it's doable however =)
adum


Thu Oct 09, 2008 4:49 pm 


MerickOWA
Joined: 07 Apr 2008 Posts: 182 Location: HkRkoz al KuwaiT 2019 HaCkEr 101 



Hrm, thats how i interpreted it the first time. I think my assumptions about what kind of data this is might be incorrect then.
No combination of b and x produced anything I recognized anyway


Thu Oct 09, 2008 8:17 pm 


Shirkit
Joined: 09 Oct 2008 Posts: 2




Hint: OR AND NOT...


Thu Oct 09, 2008 9:35 pm 


gfoot
Joined: 05 Sep 2007 Posts: 269 Location: Brighton, UK 



I decoded part of it, but not the answer. It does look a bit broken... some challenges might be intentionally easy to partially decode, but from the description of this one I wouldn't have expected that.
I have found that the Didactic Long XOR challenge has a similar fault, although I solved that one. I wondered whether it was a typo in the ciphertext.


Thu Oct 09, 2008 11:27 pm 


adum
Joined: 19 Apr 2007 Posts: 390




since tails solved the XOR 3, i don't think there's a mistake.
i think what happens is that because this 'cipher' is so weak, you can get values for x that decode some of the text but not others. for a real cipher like AES, it's an allornothing proposition.
adum


Thu Oct 09, 2008 11:41 pm 


MerickOWA
Joined: 07 Apr 2008 Posts: 182 Location: HkRkoz al KuwaiT 2019 HaCkEr 101 





I decoded part of it, but not the answer. It does look a bit broken... some challenges might be intentionally easy to partially decode, but from the description of this one I wouldn't have expected that.
I have found that the Didactic Long XOR challenge has a similar fault, although I solved that one. I wondered whether it was a typo in the ciphertext. 
Yea i see what you mean.
Edit: I've almost figured out whats wrong with Didactic Long XOR challenge. I'll send adum a pm when i figure it all out.
Edit: Solved Didactic Long. Not going to post exactly whats wrong with it, as it might make the problem more interesting


Fri Oct 10, 2008 1:22 am 


adum
Joined: 19 Apr 2007 Posts: 390




whoops, i messed up! the didactic long and XOR 3 should be fixed now. sorry about that!
thanks to merrickowa and tails for the corrections.
the _really_ sick part is that people solved these even in the broken state. especially on XOR 3, that is just insane.
thanks,
adum


Fri Oct 10, 2008 5:35 am 


tails
Joined: 10 Jun 2008 Posts: 191 Location: Tokyo 



I didn't notice these posts!


since tails solved the XOR 3, i don't think there's a mistake. 
Please count me out next time!
As MerickOWA and gfoot should have done, 'x' could be easily found anyway. So, with some tryanderrors, it was not so insane to solve it once you discover how it was broken. 'b' doesn't matter; it has only 256 possibilities.
But it's funny that I cannot solve 'Broken XOR 3' so far ...


Fri Oct 10, 2008 10:02 am 


canine
Joined: 14 Sep 2008 Posts: 189






I didn't notice these posts!


since tails solved the XOR 3, i don't think there's a mistake. 
Please count me out next time!
As MerickOWA and gfoot should have done, 'x' could be easily found anyway. So, with some tryanderrors, it was not so insane to solve it once you discover how it was broken. 'b' doesn't matter; it has only 256 possibilities.
But it's funny that I cannot solve 'Broken XOR 3' so far ... 
Sure, but if I'm understanding the problem correctly, and there is a significant chance that I'm not, b can be any 8 bit number. So if b can range from 0255, and so can x, then we have 65536 possibilities, too many to sift through to find the answer.
If I am missing something, or someone has a hint for me, it would be greatly appreciated.


Fri Oct 10, 2008 12:04 pm 


MerickOWA
Joined: 07 Apr 2008 Posts: 182 Location: HkRkoz al KuwaiT 2019 HaCkEr 101 





Sure, but if I'm understanding the problem correctly, and there is a significant chance that I'm not, b can be any 8 bit number. So if b can range from 0255, and so can x, then we have 65536 possibilities, too many to sift through to find the answer.
If I am missing something, or someone has a hint for me, it would be greatly appreciated. 
Actually, its not too bad to do. I attempted writing a program that went through all 65536 possibilities and then did a quick check of the string to see if it had good data.
So far tho, either my program is wrong, or my assumptions about the data is wrong because I haven't been successful on decrypting it ><


Fri Oct 10, 2008 2:14 pm 


adum
Joined: 19 Apr 2007 Posts: 390




okay, i messed up again! i was modding by 255 instead of 256. whoops. didactic XOR 3 and broken 3 are now fixed... sorry
adum


Fri Oct 10, 2008 4:18 pm 


tails
Joined: 10 Jun 2008 Posts: 191 Location: Tokyo 





okay, i messed up again! i was modding by 255 instead of 256. whoops. didactic XOR 3 and broken 3 are now fixed... sorry 
And the _really_ sick part is that gfoot solved it even in the broken state, that is just insane.


Fri Oct 10, 2008 4:26 pm 


gfoot
Joined: 05 Sep 2007 Posts: 269 Location: Brighton, UK 





If I am missing something, or someone has a hint for me, it would be greatly appreciated. 
It's not a large search space, and it's easy to scan the results for things that might be correct. I think most of us tripped up on the fact that none of the results actually look correct to begin with!
That said, I used a stateoftheart patternrecognition device coupled to optical sensors to scan the search space more efficiently, reducing it to O(n log n) rather than O(n^2).
Unfortunately the patternrecognition device is slower than bruteforcing it, and relatively expensive to run, but (much like Mortal Coil) it's more fun that way.


Fri Oct 10, 2008 4:38 pm 


gfoot
Joined: 05 Sep 2007 Posts: 269 Location: Brighton, UK 





And the _really_ sick part is that gfoot solved it even in the broken state, that is just insane. 
Well, the funny thing is, I was trying a 255 modulus on the old broken version, because I wasn't sure what was wrong with it (especially what could cause me to decrypt the end of the message perfectly but not the start). I'd left my solver with the wrong modulus, though, when the fixed challenge went up, and didn't notice until I'd already solved it.
No doubt there'll be another variant of the challenge up soon, where you also need to figure out the modulus. The interaction between x and m has interesting effects.


Fri Oct 10, 2008 4:54 pm 


