Author |
Topic: Breaking o t p (Read 4090 times) |
|
A
Full Member
Perder todas as esperanças é liberdade!
Gender:
Posts: 236
|
|
Breaking o t p
« on: Mar 21st, 2012, 4:43am » |
Quote Modify
|
Hi I do have 11 strings XOR encrypted with same key. Why i can break them ? at least one of them. appreciate any input Logic: For each of the possible string i and j find mssg_i xor mssg_j store in xors go a grid look up to identify possible candidates for space I'm damn new to python and below is the work so far. (uses a ^ ' ' = A , B ^ ' ' = b etc ) (Sorry just couldnt get them indented properly) Code: for i in range(11): xors.append([]) for j in range(11): msg_i_xor_msg_j = strxor(msgs[i].decode('hex'),msgs[j].decode('hex')) xors[i].append(msg_i_xor_msg_j) |
| Code: for i in range(11): print "===" for j in range(11): #for msg in xors: out = "" for char in xors[i][j]: #if ord(char) >=32 and 126>=ord(char): if (ord(char) >=65 and 90>=ord(char)) or (ord(char)>=97 and 122>= ord(char)): out += char else: out += "_" print out |
|
|
|
IP Logged |
What Doesn't Kill Me Will Only Make Me Stronger
|
|
|
Grimbal
wu::riddles Moderator Uberpuzzler
Gender:
Posts: 7527
|
|
Re: Breaking o t p
« Reply #1 on: Mar 21st, 2012, 5:35am » |
Quote Modify
|
Suppose msg[i] are the crypted messages you have, key is the key, clear[i] are the clear messages: msg[i] = clear[i] xor key. Then (msg[i] xor msg[j]) = (clear[i] xor clear[j]). You get rid of the key, but it is still the xor of 2 words. It gives nothing readable.
|
|
IP Logged |
|
|
|
A
Full Member
Perder todas as esperanças é liberdade!
Gender:
Posts: 236
|
|
Re: Breaking o t p
« Reply #2 on: Mar 22nd, 2012, 11:30am » |
Quote Modify
|
Here is what i am doing => I am assuming all 11 msg[i]'s are [a-zA-Z] or ' '(space) => observation 'A' XOR ' ' = 'a' and 'a' XOR ' ' = 'A' =>if msg[1] XOR msg[2] is a character at position k then either msg[1] or msg[2] has a space at position k if all or most of msg[1] ^ msg[j] has space at position k then it is safe enough to conclude msg[1] has space at position k . Find all spaces to get key http://en.wikipedia.org/wiki/Venona_project
|
« Last Edit: Mar 22nd, 2012, 11:32am by A » |
IP Logged |
What Doesn't Kill Me Will Only Make Me Stronger
|
|
|
SMQ
wu::riddles Moderator Uberpuzzler
Gender:
Posts: 2084
|
|
Re: Breaking o t p
« Reply #3 on: Mar 28th, 2012, 5:17am » |
Quote Modify
|
on Mar 21st, 2012, 4:43am, R0B1N wrote:Hi I do have 11 strings XOR encrypted with same key. Why i can break them ? at least one of them. appreciate any input |
| Posting assignments from Stanford's online cryptography class, are we? I'd suggest the class discussion forums are a more appropriate venue... --SMQ
|
« Last Edit: Mar 28th, 2012, 5:18am by SMQ » |
IP Logged |
--SMQ
|
|
|
A
Full Member
Perder todas as esperanças é liberdade!
Gender:
Posts: 236
|
|
Re: Breaking o t p
« Reply #4 on: May 1st, 2012, 4:41am » |
Quote Modify
|
on Mar 28th, 2012, 5:17am, SMQ wrote: Posting assignments from Stanford's online cryptography class, are we? I'd suggest the class discussion forums are a more appropriate venue... --SMQ |
| Yes It is from coursera. It was hard to discuss anything in the coursera forum without spoiling the fun for others I didn't want search engines to find it out before the deadline . Hence did not mention it
|
|
IP Logged |
What Doesn't Kill Me Will Only Make Me Stronger
|
|
|
Barukh
Uberpuzzler
Gender:
Posts: 2276
|
|
Re: Breaking o t p
« Reply #5 on: May 7th, 2012, 10:18pm » |
Quote Modify
|
on Mar 28th, 2012, 5:17am, SMQ wrote: Posting assignments from Stanford's online cryptography class, are we? |
| I am attending this class, and find it very interesting. The lecturer is excellent, albeit problems are a bit too easy, in my opinion. Anybody else enrolled? Impression?
|
|
IP Logged |
|
|
|
|