Keyword Cipher simply works based on monoalphabetic substitution. The substitution table is generated dynamically from the key, by filling up substitution table with key and padding the rest with unused alphabetic character.
Substitution Table Example:
- Key : SHIFTRY
- input : ABCDEFGHIJKLMNOPQRSTUVWXYZ
- output : SHIFTRYABCDEGJKLMNOPQUVWXZ
Vector Test Example:
- Plain Text = ALAKAZAM CHARMANDER NIDORINO
- Key = SHIFTRY
- Cipher Text = SESDSZSG IASNGSJFTN JBFKNBJK
I wrote a code of keyword cipher for PIC16F84 using MPLAB v8.0. It was successfully simulated and works the same as specification. You may freely use the code under the term of GPL v3.0. Hopefully this post can help you to grab understanding on how keyword cipher was done in a microcontroller such PIC16F84. The both screenshots of Plain Text and Cipher Text are shown below
Plain Text

Cipher Text

RELATED STUFF
Download:
Source Code | v1.0 | v1.1
PIC16F84 Datasheet
Mid-Range Reference Manual
MPLAB v8.0
Reference:
Keyword Cipher
Official Website:
- Microchip




Lots of of guys blog about this matter but you said really true words.
Comment by trerceten — 25 November 2009 @ 7:25 am