i'm paying thousands of dollars to go to school only for me to come to RU-vid and get a clear 5 minute explanation on something I've been struggling to understand for days.
Shame that you don't do more videos. I'd have definitely subscribed to you if you had more videos. I feel like this is, without a doubt, one of the best explanations I've seen of an XOR Cipher.
How do you recover a message? The Vernam encrypting messages using encryption key MOREM. The ciphertexts are C1=MAOEE and C2=RTITR which are obtained by Vernam encrypting messages M1 and M2. The encryption messages are two names. m1,1= R and m2,4=T. Please assit - I am trying to understanding how to recoverthe messages.
At 04:40 you begin showing how you can get the key by xor'ing the before and after but I'm confused as to why this matters? To get c from é surely you would need to know the key anyway? Otherwise how would you know c was the correct result?
Actually now I think about it a bit more, although I don't have any cryptography knowledge so I'm probably wrong... I guess if you were trying to crack an encrypted string and you were able to identify like 2 or 3 digit words like "to" for example you could xor "to" with what you thought might be to and use the result to xor the rest of the string to see if it makes sense?
Question - Not clear on how you find the correesponding encryption key. For example 'Mario' and it is at bit level - M=011, A=000, R=101, I=010 and O=100. The ciphertext is 'AOAMV'. How do you find the key using the XOR function?
So what you need to do is take that cipher text - "AOAMV" and the word "MARIO", convert them both into their bit sequences, then XOR the two together. The result will give you they key that you originally encyphered MARIO with.
@@CharlesLaing This assumed you actually know what the message is though. If you don't know either message but know that two messages uses the same key, how would you find the key when a second message reuses the same key?
This is a bit late to the party, but just so if anyone else comes here wondering the same thing, I'll answer it. The reason you'd be able to find out the key, is if you knew it was an XOR Cypher. IE, using say, "c" like he had before: 01000011 - c 11101001 - é if you have the original message , and then you see the encrypted message, you can figure it out if it was only an XOR Cipher. Let's say that you were given a message that was properly decrypted with the key because you were allowed. Then all you'd have to do from there, is try to open up the message intentionally WITHOUT the key so you'd receive the encrypted message. From there, you'd be able to figure out the cipher key because of how the algorithm works. IE, there are 4 scenarios that appear with an XOR Cipher 0 ^ 0 = 0 1 ^ 1 = 0 0 ^ 1 = 1 1 & 0 = 1 since we have both letters for the encrypted and the decrypted, it stands to reason that the key is what you find between them for making c decrypted to become é in the first place if every letter converts with the same pattern. That's why XOR Cipher isn't safe to use on its own. Regardless of that, even if you didn't have the decrypted message, you can still guess potential letters / characters based on the above scenarios. Example, if we end with é, we can guess things about the key for every "0" in the encrypted letter, we know that the key and the non-encrypted letter are the same. This allows us to map out potential relationships between the key and the unknown original letter. It's a heck of a lot simpler to translate these scenarios than something like: 2asp,~9034=: for instance.
I sat down and tried it, my result doesn't make much sense. The result is "(2 W" The space isn't a space it's a character called Start Of Heading which doesn't have a printable form The answer to the riddle is the letter x
kill cap well, you might find one file that is encrypted (or a part of it) that you do know while it is not encrypted, with just the length of the key worth of (sequential) encrypted file data, you can recreate the key
that's why we create a random key, and encrypt that with another key obtained from the password and store the encrypted key in the file somewhere and decrypt it first, and use it to decrypt the actual data with. Sine you only encrypted the key with your actual password, there are much less ways to now get this random key, without the password