I've begun a course in crypto on coursera and the first homework was writing a vigenere(xor) cracker. It works, which was a rush :) but it makes one core assumption, one has encrypted a natural language text that the script can use frequency analysis on. Therefore doesn't work if one encrypted an image or a compressed file. How does one do it if frequency analysis isn't an option?
Asked
Active
Viewed 235 times
1 Answers
1
AFAIK vigenere cipher is a plain subsitution algorithm with arbitrary key length, destroying statistical patterns (f.e. of natural languages) but not conducting any transposition.
Btw. a classic approach to crack a vigenere cipher is the Kasiki-Test (https://en.wikipedia.org/wiki/Kasiski_examination) which might give you information reagrding the key length.
If you try to decrypt a file format (jpeg, gif, zip etc.) you actually know at least the first bytes (fileheader) as they are defined by convention: f.e. a zip file always starts with 0x04034b50 (https://en.wikipedia.org/wiki/Zip_%28file_format%29) which gives you the first 4 bytes for your decryption table.

Oliver Jl
- 61
- 4
-
This answer goes from worst to best. That the Vigenère cipher destroys statistical pattern is a strong falsehood. The Kasiki test depends on it. That there is known plaintext for many encoding formats is on the other hand completely true and a good answer. Please try and format your questions and answers to the best of your ability (the Kasiki test is actually a test for a Greek cucumber recipe). Try and avoid acronyms such as AFAIK, BTW, f.e. et cetera. – Maarten Bodewes May 15 '16 at 11:51