Project 6, 2015 Research Experience for Teachers Project 4, 2016
Caesar Cipher

Secret Key, Public Key, Hash Algorithms, Protocols, Authentication, Integrity, Confidentiality, Availability

 

Instructions:
 
    The text in the field labeled "encrypted:" is (or is close to being) a famous quote that is encrypted by shifting the letters A-Z, space, and the characters comma and single quote by some number of positions to the left or right. The JComboBoxes at the bottom of the applet represent a guess at the shift that was used to encrypt. There are two ways to experiment with the applet.
  1. Make selections and click the "Decrypt" button. For example, if you think that the encrypted character A maps to the plaintext character D then drop the list labeled A and select D. The change will be registered when you click the "Decrypt" button. Then, the translation to plaintext is shown in the "decrypted:" field. If a JComboxBox setting is - (the default for all characters) then there will be no translation to plaintext for that character and blank spaces will occupy the plaintext positions corresponding to that character's position in the "encrypted:" field. Click the "Reset" button to cause all JComboBox settings to revert to - and the "decrypted:" field to be erased.
  2. Click the "Reset" button to cause all JComboBox settings to be -, then select a character from a single JComboBox. Next, click either + or -. In the case of selecting +, an increasing caesar cipher will be automatically set around the character that you selected, in the case of - a decreasing caesar cipher will be set. See the next paragraph for an example.

Tip: It is usually not hard to determine which character translates to a space. Suppose it is X. Then select the space character in X's JComboBox and click either the + or - button.

Example: Suppose the encrypted quote is the following:
  WZEDODUPZOJZDOKSZTISEJYDZEWBSZWJ'DPOJQ

This quote has a lot of Z characters and it is reasonable to suppose that this character translates to space. Click "Reset" then Select ' ' from the pull-down menu of Z's JComboBox. Click the + button to get this:
  X FEPEVQ PK EPLT UJTFKZE FXCT XK,EQPKR

That did not work so click on "Reset" then select the space character from Z's menu and click the - button. The result is:
  A STITCH IN TIME DOESN'T SAVE ANYTHING

Why this?

 
    This is the classic "Caesar Cipher" where the key is just a shift in position of each character allowing for wrap-around. It is really easy to break. Theoretically, for this example, you only have to try at most 27*2 different alphabet-wide position shifts (a shift of 0 is disallowed for obvious reasons).