Deciphering an enciphered message

One of the easiest ways to encipher a message is to use "monoalphabetic substitution" - you go through the message and substitute, for example, change every "d" to "T", every "i" to "B"...). To crack a message encrypted this way, you can perform a simple frequency analysis and use this to guess which letter matches with which. (For example, "e" is normally the most common letter used in English, so you can guess that the most common letter in the ciphertext corresponds to "e".)

Substitution can be made more secure by using homophones - for example, we might give ourselves the option to encode "e" as either "Y" or "4" or "%", so that none of these is the most commonly-used character. However, I've written a script to perform multi-dimensional frequency analysis, which should make it possible to crack such a cipher. You can look at not just the frequency of a single character, but also of a combination of two characters (a "digraph") or of three characters (a "trigraph").


To crack a given message:

If you don't know which language the message is in, you can create a plaintext analysis for each possible language. The patterns revealed in the two-dimensional table should help you to find a best fit and decide which language to use to attempt to decipher the message. For example, one tell-tale 'blip' in the english language is a dark spot for 'TH' in the upper-mid region of the table (because 'T' is very common, but 'H' is not so common, but 'TH' is usually the most common digraph of all!).

Enter your ciphertext or comparison text here:

If you want to look at some examples of different languages processed through this system follow these links:

If you'd like to try out your skills see if you can decipher this message (I still haven't managed to decipher it!):

IXDVMUFXLFEEFXSOQXYQVXSQTUIXWF4FMXYQVFJ4FXEFQUQXJFPTUFXMX4ISSFL
QTUQXMXRPQEUMXUMTUIXYFSSFI4MXKFJF4FMXLQXTIEUVFXEQTEFXSOQXLQ4XV
FWMTQTUQXTITXKIJ4FMUQXTQJMVX4QEYQVFQTHMXLFVQUVIXM4XEI4XLQ4XWIT
LIXEQTHGXJQTUQXSITEFLQVGUQX4GXKIEUVGXEQWQTHGXDGUFXTITXDIEUQXGX
KFKQVXSIWQXAVPUFXWGXYQVXEQJPFVXKFVUPUQXQXSGTIESQTHGX4FXWFQFXS
IWYGJTFXDQSFIXEFXGJPUFXSITXRPQEUGXIVGHFITXYFSSFI4CXC4XSCWWFTIXSOQX
CXYQTCXYIESFCX4FXCKVQFXVFUQTPUFXQXKI4UCXTIEUVCXYIYYCXTQ4XWCUUF
TIXLQFXVQWFXDCSQWWIXC4FXC4XDI44QXKI4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