This page contains a JavaScript implementation written by Leland Aldridge of Bruce Schneier's output-feedback mode stream cipher Solitaire v1.2

To encrypt or decrypt a message using Solitaire, the first step is to put together a deck of cards. This can be done by clicking "Shuffle" for a random order, or entering a Passkey and clicking "Key." For an unkeyed deck, leave the Passkey field blank and click "Key." To manually enter a deck, type the value of each card separated by a comma into the Starting Deck field, like it appears when generated by the program. If the card is a club, it is the value shown. If the card is a diamond, it is the value plus 13. If it is a heart, it is the value plus 26. If it is a spade, it is the value plus 39. 53 for joker A and 54 for joker B.

Next, enter the message length. If you are unsure of the message length, enter a number you know to be larger than the length. Then click "Generate Keystream," and a keystream will appear in the Keystream field.

Lastly, enter either the cleartext or ciphertext, click the appropriate Encrypt/Decrypt button, and then click "GO GO GADGET!"

In all cases, use ALL CAPS and NO SPACES.


Key Shuffle

Starting Deck

Message Length: Generate Keystream




Encrypt   Decrypt   GO GO GADGET