Keyword Substitution Cipher
A keyword substitution cipher is a simple substitution cipher. It uses a keyword to create a replacement alphabet. The replacement alphabet begins with the letters in the keyword and finishes with the remaining letters of the normal alphabet in sequence.
Suppose that you wanted to encipher the text
the moment echo saw narcissus she was in love. she followed him like a starving wolf following a stag too strong to be tackled.
The first step is to choose a keyword:
You need to remove from the keyword any letter that has already been used. So here it is necessary to remove the second 'S', 'T', 'U', and 'I', and the third 'T':
The letters in the keyword are used to begin a replacement alphabet:
a b c d e f g h i j k l m n o p q r s t u v w x y z S U B T I O N
The replacement alphabet is then completed with those letters of the normal alphabet that have not already been used. One method is to use the letters in sequence, starting from the beginning of the alphabet:
a b c d e f g h i j k l m n o p q r s t u v w x y z S U B T I O N A C D E F G H J K L M P Q R V W X Y Z
Another method is to use the letters in sequence, starting with the first available letter after the final letter of the keyword:
a b c d e f g h i j k l m n o p q r s t u v w x y z S U B T I O N P Q R V W X Y Z A C D E F G H J K L M
Note what happens when you get to the end of the normal alphabet: you go back to the beginning.
Once you have a substitution table, then you can encipher the plaintext. Using the second substitution table, you get
FPI XZXIYF IBPZ ESJ YSDBQEEGE EPI JSE QY WZHI. EPI OZWWZJIT PQX WQVI S EFSDHQYN JZWO OZWWZJQYN S EFSN FZZ EFDZYN FZ UI FSBVWIT.
If you remove the punctuation and place the letters in blocks of 5, then this becomes
FPIXZ XIYFI BPZES JYSDB QEEGE EPIJS EQYWZ HIEPI OZWWZ JITPQ XWQVI SEFSD HQYNJ ZWOOZ WWZJQ YNSEF SNFZZ EFDZY NFZUI FSBVW IT
This section is under construction.