A friend described this cipher to me the other day, but if it has an official name, I'm unaware of it. The same 26 cipher alphabets that are used in the Vigenère cipher are used here, but rather than using a code word to determine which alphabet is used for a given character, the previous characters of the plaintext are used. The numerical value of every letter which comes before a given letter (a=1, b=2 etc) is added - for example, if the first letter of plaintext is H, then the 8th alphabet is used to encrypt the second letter. If the first five letters of plaintext are HELLO, then the 26th alphabet is used to encrypt the sixth letter (8+5+12+12+15 = 52, 52-26 = 26). A randomly chosen alphabet, agreed upon by sender and receiver, is used to encrypt the first letter. How secure is this? Just relative to other polyalphabetic ciphers, like Vigenère, not modern encryption methods, which I know are arbitrarily more secure.
-
$\begingroup$ This sounds a lot like the autokey cipher en.wikipedia.org/wiki/Autokey_cipher However, your cipher can be broken by simply bruteforcing the 26 possible first letters (even by hand) and then checking which plaintext makes sence, so the cipher is really insecure. $\endgroup$– VincBreakerCommented Aug 24, 2017 at 19:59
-
$\begingroup$ Actually, it sounds like there is no key at all. That means it is not a cipher, similar to ROT13, and has no security at all. $\endgroup$– tyloCommented Aug 25, 2017 at 9:36
2 Answers
This is in fact the original Viginère method with a one-letter key.
The system as proposed by him, use a keyword $K$ of length $n$ for the first $n$ letters of a text, and then used the plaintext (from the start onwards) as the key for the rest. (it'a a "plain-autokey" cipher). He did not repeat the keyword, which is a somewhat weaker system, which is how his cipher is often represented nowadays.
It's still statistically weak, by autocorrelation it's easy to find the length of the keyword, and then it's reading in depth, essentially. Friedman wrote about this method on it in one of his cryptanalysis books.
Your friend's system only has a 1-letter (or one-alphabet) keyword, essentially. It doesn't matter if we use some random alphabet for the first, you just try all first plain letters and decrypt from the second letter onwards. Only one will make sense, normally. At least Viginère' system is not directly brute forcable in that way for long keywords.
This is a very weak cipher. For a single message only a 26 possibility key is used. Which is trivially brute forced(even by hand). The tiny effective key makes this very weak, weaker then a substitution or a simple vigenre cipher. For full key recovery you will need multiple messages but that is just is just because each message doesn't use most of the key.