COMP 133 - Assignment 1

Due Dates

This assignment is in two parts, codemaking and codebreaking. The first part is due September 13 in class and the second part is due Monday November 13 in class. For the first part each student must hand in their own work (ie, code). For the second part, you may work in groups of any size.

Part One

In this part of the exercise you are to invent a cipher of your own. It can be a variation on a cipher you have read about or it can be entirely of your own devising. It must however conform to the following rules:

1. It should be a cipher not a code. That is, it should take any plaintext consisting of characters of the alphabet and transform it into a ciphertext consisting of characters on a standard keyboard without recourse to codebooks or other extraneous material not available to all students of COMP 133. (Note: You can assume that all students have a copy of Simon Singh's book.)

2. It should be a secret key symmetric cipher. That is, the coding and decoding operations should depend on the existence of a secret key shared by the sender and receiver. This key should be of reasonable length, something that can be remembered without too much effort, e.g., a word or short phrase.

3. The coding and decoding operations should be doable using only pencil and paper. The idea is that the code will be used in the field by a spy without access to computers or other tools. Thus the time it takes to encode and decode without errors should be reasonable, say at least 5 characters per minute.

You are to hand in three items:

A. A detailed description of the coding and decoding operations. This should be sufficiently detailed so that anyone given a key and a plaintext could (using pencil and paper) produce the corresponding ciphertext without error and given a key and a ciphertext, unambiguously produce the plaintext. Preferably this information should fit onto at most two pages and should include a small example different than the one asked for below.

B. On a separate piece of paper which is otherwise blank provide the result of encoding a randomly chosen paragraph from the main portion of Simon Singh's book (not including any of the appendices). The paragraph should consist of at least 200 characters. In performing the encoding, ignore all punctuation and spaces and assume all letters are lower case. Please send a copy of the cipher text by email to dkrizanc at wesleyan dot edu. Send either as a plain text message or as a doc attachment.

C. On a separate piece of paper which is otherwise blank provide the key used in encoding the paragraph chosen in B as well as the original plaintext along with the page number it appears in the book.

Avoid making any of the three parts identifiable, e.g., place your name on a separate cover sheet and paper clip the parts together. If you have any questions about the rules just ask me.

Part Two

Soon after all of the first parts are received, I will hand out parts A and B from above in random order, i.e., it will not be obvious which encoding technique produced which paragraph (though this may be possible to detect depending on the technique). Your goal in this part is to decode as many of encoded paragraphs as possible. You are not limited to cryptanalysis in your search for answers. (I.e., harmless snooping may be alright but please stop short of breaking and entering - kidnapping and torture is right out!) For each part B that you break hand in the corresponding plaintext, the key and the method used for the encoding. (It may be possible to figure out the plaintext without discerning the method or discovering the key. In this case, just hand in the corresponding plaintext.)

Grading

Points will be awarded for each code you break and points will be deducted for each time your own code is broken. The weight of breaking vs not being broken will be determined by the result of the exercise (i.e., it will be scaled) but in general the idea is the most points will be awarded to someone who breaks a lot of codes and has few people break hers. Note that you can work in groups for the second part. If you decide to work with someone after handing in part one, it will be assumed that you have broken each others codes.

Report problems to dkrizanc at wesleyan dot edu Top of Page