Brain Teasers
Brain Teasers Trivia Mentalrobics Games Community
Monoalphabetic
Caesar
Atbash
Keyword
Pigpen / Masonic
Polybius Square
Polyalphabetic
Vigenère
Beaufort
Autokey
Running Key
Polygraphic
Playfair
Bifid
Trifid
Four-square
Transposition
Rail Fence
Route
Columnar Transposition
Others
Book
Beale
Morse Code
Tap Code
One-time Pad
Scytale
Semaphore
ASCII
Steganography
Add to Google Add to del.icio.us

More ways to get Braingle...

Codes and Ciphers :: Rail Fence

In the rail fence cipher, the plaintext is written downwards on successive "rails" of an imaginary fence, starting a new column when the bottom is reached. The message is then read off in rows. For example, if we have 3 rails and a message of "This is a secret message", you would write out:

T S A C T S G
H I S R M S E
I S E E E A J

The last J is just a random letter to fill in the space. The secret message is then condensed and regrouped.

TSACT SGHIS RMSEI SEEEA JGURL

To decipher a message you must know the number of rails that were used to encipher it. You then break up the letters into equal groups for each rail. For example, if you are using 3 rails, you would break the secret message into 3 equal groups. Now you stack the groups on top of each other and read off the message vertically. If you get gibberish, then there are probably some extra letters tacked on the end of the message that are throwing off the grouping. Try removing one letter from the end and try again.


Rail Fence Encoder / Decoder

Number of rails:

Plaintext
Ciphertext

 


Source: Wikipedia


Table of Contents
Books about Cryptography

   



Online Now: 23 users and 464 guests

Copyright © 1999-2014 | Updates | FAQ | RSS | Widgets | Links | Green | Subscribe | Contact | Privacy | Conditions | Advertise

Custom Search





Sign In A Create a free account