Page 1 of 1

Didactic XOR Cipher 2

Posted: Wed Nov 10, 2010 1:29 pm
by johnpatcher
Hi,

I'm probably overlooking something or misinterpreting the text, therefore I've to ask you for further advices.

What I've done so far. I suppose that the hex encoded string is encrypted the same way as in "Didactic XOR Cipher 1", so I've decrypted it in the same way.

The text now says that each character has been xor'd by a byte. I suppose this means that each character is xor'd with the same byte. as it would be an one time pad otherwise, which is proven to be unbreakable, isn't it?

As a byte can store 8 bits, there are only 8 possible keys? I've tried every one of these 8, and couldn't find a suitable solution.

I'm now supposing that I've done something wrong, but can't imagine what that could be. Any clues would be appreciated.

Re: Didactic XOR Cipher 2

Posted: Wed Nov 10, 2010 1:35 pm
by HugStuart
johnpatcher wrote:Hi,
The text now says that each character has been xor'd by a byte. I suppose this means that each character is xor'd with the same byte. as it would be an one time pad otherwise, which is proven to be unbreakable, isn't it?
Right
johnpatcher wrote: As a byte can store 8 bits, there are only 8 possible keys? I've tried every one of these 8, and couldn't find a suitable solution.
One byte can store 8 bits, this leads to 256 different keys: 00000001, 00000010, 00000011, ..., 11111110, 11111111

Re: Didactic XOR Cipher 2

Posted: Wed Nov 10, 2010 4:03 pm
by johnpatcher
HugStuart wrote:One byte can store 8 bits, this leads to 256 different keys: 00000001, 00000010, 00000011, ..., 11111110, 11111111
Sorry, I meant 256. I've looked over all of them, and couldn't find anything that makes sense at all :(.

Re: Didactic XOR Cipher 2

Posted: Wed Nov 10, 2010 5:04 pm
by HugStuart
johnpatcher wrote: Sorry, I meant 256. I've looked over all of them, and couldn't find anything that makes sense at all :(.
Did you XOR the whole message for each byte and converted it to char?

Posted: Wed Nov 10, 2010 5:08 pm
by johnpatcher
Ok, got it, had a mistake in my program :(. Don't know whether this thread spoils too much?

Using Perl

Posted: Sun Dec 05, 2010 7:02 am
by hughr2005
Hey,
I'm using perl, and I've generated a list of the hex number xor'd as above with each number up to 256. The list is printed in decimal, but now I'm wondering if there's a way to convert each number to characters? I presume it uses ascii, but I can't find a way of converting the numbers to ascii characters. Is there a method in perl, or will I have to switch to some other language like ruby to interpret the data?
Thanks

Posted: Mon Dec 06, 2010 8:52 pm
by megabreit
"perldoc perlfunc" and search for the chr function.

got it but still :(

Posted: Tue Jan 04, 2011 8:35 am
by kamikataz
hii, i got the key , have the text decrypted but still answer is not accepted in any form ,,

the " starts but do not ends, which portion is the answer??

what i got is like

xxxxxxxxxxxxxx "xxxbhbjh xxxxxxxxxx

where "xxxbhbjh is a combination of 2-3 english words english word rest is all in english.

please help ....

Re: got it but still :(

Posted: Tue Jan 04, 2011 2:42 pm
by laz0r
kamikataz wrote:hii, i got the key , have the text decrypted but still answer is not accepted in any form ,,

the " starts but do not ends, which portion is the answer??

what i got is like

xxxxxxxxxxxxxx "xxxbhbjh xxxxxxxxxx

where "xxxbhbjh is a combination of 2-3 english words english word rest is all in english.

please help ....
PM me with your solution and I'll tell you. (I have solved it already, btw :P )

Posted: Tue Apr 30, 2013 7:57 pm
by meis
I have a problem, i'm doing this w/ PHP, like about every other challenge.
My script does the following:
for every char of the string, it converts in base 2 (binary) and xores it with 79 in base 2, then converts the result in base 16 and concatenates them. It gives me a string (27112711274e2710274f272712112711271027102710), but it's not correct.

Where have I mistaken (and does "to mistake" exists in english?)? xD

EDIT: I just noticed, I was talking about didactic XOR 1, i was writing in the wrong topic... I'm a little too old for this xD