Running Key Cipher

The Running Key Cipher is a method of encryption that uses a keyword or phrase as a key for the encryption process. This cipher is essentially a variant of the Vigenère cipher but relies on a continuous key rather than a repeating one. The technique was developed during the 19th century, with roots traced back to various classical encryption methods, though its precise origins are less documented than other ciphers. It was used primarily for securing messages where a one-time pad or a similar technique was impractical.

The Running Key Cipher works by taking a plaintext message and aligning it with a long, non-repeating key. The key is extended as needed to match the length of the plaintext. Each letter of the plaintext is then shifted according to the corresponding letter of the key. This method offers a significant improvement in security over simple substitution ciphers, as the shifting is based on a variable key rather than a fixed substitution.

Example:

Consider the plaintext message "MEET ME AT DAWN" and the key "LIMESTONE".

  1. Align the key:

    Plaintext:  M E E T   M E   A T   D A W N
    Key:        L I M E   S T   O N   E I I I
  2. Encrypt each letter:
    1. M (12) + L (12) = X (24)
    2. E (5) + I (9) = N (14)
    3. E (5) + M (13) = R (18)
    4. T (20) + E (5) = Y (25)
    5. M (12) + S (19) = F (6)
    6. E (5) + T (20) = Y (25)
    7. A (1) + O (15) = P (16)
    8. T (20) + N (14) = H (8)
    9. D (4) + E (5) = I (9)
    10. A (1) + I (9) = J (10)
    11. W (23) + I (9) = F (6)
    12. N (14) + I (9) = V (22)
  3. Resulting Ciphertext:

    The plaintext "MEET ME AT DAWN" can be encrypted to "XNR YFY PHIJ FV".

    Mapping Table:

Here’s how the Running Key Cipher encryption works for the letters involved:

Plaintext PairKey PairShift (Plaintext + Key)Ciphertext
ML(12 + 12) mod 26 = 24X
EI(5 + 9) mod 26 = 14N
EM(5 + 13) mod 26 = 18R
TE(20 + 5) mod 26 = 25Y
MS(12 + 19) mod 26 = 6F
ET(5 + 20) mod 26 = 25Y
AO(1 + 15) mod 26 = 16P
TN(20 + 14) mod 26 = 8H
DE(4 + 5) mod 26 = 9I
AI(1 + 9) mod 26 = 10J
WI(23 + 9) mod 26 = 6F
NI(14 + 9) mod 26 = 22V

This table shows how each letter in the plaintext message interacts with the corresponding letter in the key to produce the final ciphertext. The Running Key Cipher emphasizes the importance of the key in encryption, highlighting how a longer, non-repeating key significantly increases security compared to traditional methods.