Free Essay

Cryptography - Itec 5001

In:

Submitted By tpolwort
Words 1748
Pages 7
Administrative Information Sections applies to: | ITEC and CRJU, ALL (both U and G sections) | Covers Concepts From | Chapter 9 (and other material) | Date Assigned | Monday, November 10, 2014 | Date / Time Due | Monday, December 1, 2014, 11:59pm. Due to the proximity to the end of the semester, only a ONE day late period will be allowed, until Tuesday, December 2, @ 11:59pm | Method of Submission | You may download this document, enter your answers directly into it, and upload it back into Desire-2-Learn (D2L). The assignment must be submitted via D2L – no other method will be accepted | Percentage of overall grade | This lab, including all required deliverables, is worth 6% of the course’s overall grade, or 60 points out of 1000. | DELIVERABLES | For the Virtual Lab component: Make sure that you transfer all files/images indicated in the lab to our local computer. For the part of the assignment in which you answer questions, they should be answered in THIS document.For the Manual / CrypTool 1 component: all answers are to be entered in THIS document. | Value of each question | See each question or component | BONUS | See below |

In this assignment, you will: * Encrypt (not decrypt) a message “by hand,” using techniques used from the Whitman/Mattord Principles of Information Security online pdf file and online lecture. * After doing that, you will download the Cryptool 1 software used to perform cryptography. You will then perform the same cryptographic techniques using Cryptool 1. * Before or after performing the above two parts of the assignment, you will do the Virtual Cloud Lab exercise on Cryptography. * When totally complete, you will be requested to take a survey regarding the effectiveness of performing cryptography by hand versus by software. If you take this survey, regardless of your responses, you will be awarded 10 extra credit points. The survey will be made available to you no later than noon on Monday, December 1. It will be open until Monday, December 8, at noon.

All percentages below are in terms of percentage of the 60 points for the assignment ITEM (by Hand) | Value | ITEM (CrypTool1) | Value | RSA | 15% | RSA | 15% | Vernam | 5% | Vigenere | 10% | Vigenere | 5% | XOR | 10% | XOR | 5% | | | | Using Virtual Cloud Lab | | | | Files from Virtual Lab | 10% | | | Answers to each question | 5% or 25% | | |

I. Cryptography By Hand

The first question uses the concepts of the RSA Algorithm to encrypt a message. You are not required to determine the public key and the private key, these will be given to you (the derivation is provided online). You will be required to use the public key given to you to encrypt the message. Please note that these are DIFFERENT prime number values than in the text, but they DO work. To familiarize yourself with this methodology, you should read the Adobe pdf file.

Your encrypted values for question 1 must include leading zeroes to the third digit. So, for example, if your ciphertext results in 83, you must code it as 083

1. Encrypt the message SENDHELPNOW (no spaces) using the following public key (proven to work): See Table 8-5. Note the different P, Q, and (N,E) than in the Adobe pdf example from the Whitman/Mattord text.

P = 7, Q = 37, so public key is (N,E) = (259,7). The message is SENDHELPNOW (broken into two tables so it will fit)

Message | S | E | N | D | H | E | L | P | (Text)^E | 19 | 05 | 14 | 04 | 08 | 05 | 12 | 16 | Ciphertext | 061 | 166 | 245 | 067 | 029 | 166 | 194 | 086 |

Message | N | O | W | (Text)^E | 14 | 15 | 23 | Ciphertext | 245 | 183 | 051 |

2. Using the very same message and the Vernam Cipher depicted on page 362 in the Adobe pdf example from the Whitman/Mattord text, produce the correct ciphertext.

Plaintext | S | E | N | D | H | E | L | P | N | O | W | One-time pad | F | P | Q | T | M | S | D | J | Y | H | Y | Sum | 25 | 21 | 31 | 24 | 21 | 24 | 16 | 26 | 39 | 23 | 48 | After Modulo Subtraction | 25 | 21 | 5 | 24 | 21 | 24 | 16 | 26 | 13 | 23 | 22 | Ciphertext | Y | U | E | X | U | X | P | Z | M | W | V |

3. Using the Vignere Square and the keyword XHTML, encrypt the very same message.

X | H | T | M | L | X | H | T | M | L | X | S | E | N | D | H | E | L | P | N | O | W | P | L | G | P | S | B | S | I | Z | Z | T |

4. Using Exclusive OR (XOR) with the characters BAT in ASCII binary as the key, and the word DOG as your plaintext, create the sequence of cipher bits.

BAT | 0 | 1 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | DOG | 0 | 1 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 1 | 0 | 0 | 1 | 1 | 1 | 1 | 0 | 1 | 0 | 0 | 0 | 1 | 1 | 1 | | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 | 1 |

II. Cryptography Using Cryptool

This assignment will use one of the most commonly used Cryptography/Cryptanalysis tools – CrypTool 1. The CrypTool “family” of Cryptography/Cryptanalysis tools also includes CrypTool 2 and JCrypTool. But CrypTool 1 is open-source, doesn’t require Java or MS Visual Studio installations, and is the easiest to use. So that’s what we will be using.

A link to CrypTool 1 is provided in the Lab module. Go to the web site, download CrypTool1, and install it.

To do the various exercises, you are going to need use an input text file, and then apply various cryptographic methods against that file. This file is also provided for you in the Lab organizer folder – you will need to use it for each exercise.

Steps for Performing the Exercises 1. Download CrypTool1 and install it. 2. Read through the Readme txt file 3. Open up CrypTool1. Notice that you are provided with a “startingexample” text file. Don’t delete it, just minimize it. 4. Download the HW-example file from D2L to your desktop. This is what you will use for the various assignments. 5. Perform the assignments, as detailed below. For each exercise, copy your results into this document.

Symmetric, Classic – Vigenere

Apply the key INFOSEC to the HW-example input file. Record the results.
IERGLVQVT'X ASWEWG NG UERBNNB YIQZTJ

Then perform decryption against the same input string, using the same key. You should get the original result (don’t paste it in here)
Now change the key to demonstrate what happens if the key is copied incorrectly. Encrypt using INFOSEC, decrypt using INFOSED. Copy and paste your incorrectly decrypted result here:

ARMSTRNNG'S MASBOT IS CAOTAIN GENRGE

Symmetric, Classic: Exclusive OR (XOR):

For this exercise, you will use an XOR key of LET to decrypt the simple message of DOG. But you are first going to have to convert LET to Hexadecimal. Your answer will be displayed in Hexadecimal. You will need to copy and paste (or just type in) your answer, in hex, below.
4c4554

First, open up the file DOG.txt provided to you. Then select Symmetric, Classic, XOR. The key in LET in hexadecimal (you will have to determine this on your own). Click encrypt, and the resulting hexadecimal encryption will be displayed. Paste it below. You can decrypt using your key in hexadecimal to prove that your encryption was correct.
08 0A 13

Generation of Primes for RSA Encryption – RSA Encryption

RSA Encryption requires the use of two prime numbers. The example in Whitman/Mattord’s Principles of Information Security, provided to you as an Adobe pdf file (and the online lecture), uses two very simple primes, 3 and 11 (P and Q), to demonstrate the math involved in generating the public key (N,E) and the private key (N,D). Since it is so hard to come up with two relatively small prime numbers that will work, you will use CrypTool1 to do this for you.

Follow the detailed steps below to perform this exercise using CrypTool1 1. You will NOT be using the input file for the message. That would generate too long of an answer. You will just use (you’ll have to eventually input it yourself) the word (all UPPER CASE) ARMSTRONG 2. You will need to click on the menu Individual Procedures RSA Cryptosystem RSA Demonstration 3. In RSA Using the Private/Public Key at the top, leave the first radio button selected. 4. You can’t determine a good pair of primes, so let the computer do it for you. Click on Generate prime numbers, which will open up a new dialog box. 5. Leave everything as it is, and just click on Generate prime numbers 6. Record those primes here: p = 211 q = 233 7. Click Apply Primes 8. They, and everything associated with them Public Key e and Private key d, are “magically” loaded into the dialog box. Record the public and private keys here: public key e = 2^16+1 private key d =44273 9. Under RSA encryption using e / decryption using d leave the input as text and click on Options for alphabet . . . 10. Here are the options you should use in this dialog box: a. Specify alphabet should be clicked – it shows all 26 upper case letters. It reads 27, but that is because blank is included. However, your input of ARMSTRONG doesn’t have blanks b. RSA variant should be normal c. Method for coding block into numbers should be b-adic d. Block length should be 1. We are encoding our message character by character e. Number system should be decimal f. Click OK 11. Now where the dialog box asks you to Enter the message, key in ARMSTRONG as upper case, no lower case letters. 12. CLICK ENCRYPT

DO NOT CLOSE THE DIALOG BOX (unless you want to do all this all over again)!!

So what are you going to report back to me? You are going to fill in the table below, with your answers. Since every student may have different pairs of original primes, every student’s answer may be different. That’s OK, because I’m going to check everyone’s work using the tool. Since these should be five digit numeric sequences (for each letter) you MUST include leading zeros.

03316 # 25674 # 16226 # 00559 # 00500 # 25674 # 39271 # 29564 # 09472

Message | A | R | M | S | T | R | O | N | G | Encryption into ciphertext | 03316 | 25674 | 16226 | 00559 | 00500 | 25674 | 39271 | 29564 | 09472 |

Similar Documents