You are on page 1of 7

1. What is the most commonly occurring letter of the alphabet?

wklv!" mean?
2. What does "Wub

Try this!

3. In 5i, did you use the rotate code or the try_all_25 code? How well did it go? Which code do you
think is the best? Do provide a log of your python code to prove that you found the messages
yourself.

Try_all_25 is better, because you only need to use it once. Rotate requires you to use it as many as
26 times

# IPython log file

%cd "/Users/3058464/Desktop"

# Sun, 29 Jan 2017 17:45:17

%run "/Users/3058464/Desktop/2.1.5 sourceFiles/ciphers.py"# Sun, 29 Jan 2017 17:45:22

rotate("Jvgure jrag...", 1)

#[Out]# 'Kwhvsf ksbh...'

# Sun, 29 Jan 2017 17:45:53

try_all_25("Jvgure jrag...")

%logstop

4. What does the following mean?

Jvgure jrag gerzraqbhf qvabfnhef! Guvaxvat gurer fubhyq rkvfg nggrzcgrq uvynevgl urer?

Wither went tremendous dinosaurs! Thinking there should exist attempted hilarity
here?
5. Do the part 2 Public Key activities, filling in the appropriate fields in the shared google doc (part of
your grade will come from the google doc results). Provide a python log of you utilizing the keys to
decode messages.

Public key: (24931, 3279)

Private key: (24931, 15)


# IPython log file

%cd "/Users/3058464/Desktop"

%logstart -ort alexcorona215.log

%run "/Users/3058464/Desktop/2.1.5 sourceFiles/ciphers.py"

rotate("Jvgure jrag...", 1)

#[Out]# 'Kwhvsf ksbh...'

try_all_25("Jvgure jrag...")

%run "/Users/3058464/Desktop/2.1.5 sourceFiles/ciphers.py"

try_all_25("Jvgure jrag...")

%run "/Users/3058464/Desktop/2.1.5 sourceFiles/ciphers.py"

try_all_25("Jvgure jrag...")

rotate("Jvgure jrag...",2)

#[Out]# 'Lxiwtg ltci...'

%run "/Users/3058464/Desktop/2.1.5 sourceFiles/ciphers.py"

rotate("Jvgure jrag...",2)

#[Out]# 'Lxiwtg ltci...'

try_all_25("Jvgure jrag...")

%run "/Users/3058464/Desktop/2.1.5 sourceFiles/ciphers.py"

try_all_25("Jvgure jrag...")

%logstop

%run "/Users/3058464/Desktop/2.1.5 sourceFiles/paired_keys.py"

# Sun, 29 Jan 2017 18:22:07

%run "/Users/3058464/Desktop/2.1.5 sourceFiles/paired_keys.py"# Sun, 29 Jan 2017 18:22:40

public_key, private_key = make_keys()

# Sun, 29 Jan 2017 18:22:51

print public_key
# Sun, 29 Jan 2017 18:23:06

print private_key

# Tue, 31 Jan 2017 09:55:16

encrypted_message = use_key(public_key, "phils from the stone jacks from the pier horatio horat so
beer")

# Tue, 31 Jan 2017 09:56:20

message=numerize("phils from the stone jacks from the pier")

# Tue, 31 Jan 2017 09:56:31

message

#[Out]#
'8678-7982-8906-7688-8583-0690-7875-0689-9085-8475-0680-7173-8189-0676-8885-8306-9078-7
506-8679-7588'

# Tue, 31 Jan 2017 10:04:16

ab="3982-8206-4575-8480-7906-8682-7195-7588-8906-7188-7506-7475-7174-0690-8506-8375"

# Tue, 31 Jan 2017 10:04:47

decrypted_message = use_key((76127, 17),ab)

# Tue, 31 Jan 2017 10:04:52

decrypted_message

#[Out]#
'67404-50373-12712-46424-72083-61712-30357-12677-61354-35072-52986-40988-74978-2114-54
497-67691'

# Tue, 31 Jan 2017 10:05:27

plain_message = denumerize(decrypted_message)plain_message

# Tue, 31 Jan 2017 10:05:44

plain_message = denumerize(decrypted_message)

# Tue, 31 Jan 2017 10:06:08

denumerize(67404-50373-12712-46424-72083-61712-30357-12677-61354-35072-52986-40988-74
978-2114-54497-67691)

# Tue, 31 Jan 2017 10:06:22


denumerize("67404-50373-12712-46424-72083-61712-30357-12677-61354-35072-52986-40988-74
978-2114-54497-67691")

# Tue, 31 Jan 2017 10:07:26

authenticated_message
="3982-8206-4575-8480-7906-8682-7195-7588-8906-7188-7506-7475-7174-0690-8506-8375"

# Tue, 31 Jan 2017 10:07:48

jons_public_key = (76127, 17)

# Tue, 31 Jan 2017 10:07:59

use_key(jons_public_key, authenticated_message)

#[Out]#
'67404-50373-12712-46424-72083-61712-30357-12677-61354-35072-52986-40988-74978-2114-54
497-67691'

# Tue, 31 Jan 2017 10:08:07

plain_message = denumerize(_)

# Wed, 01 Feb 2017 09:39:18

message=numerize("phils from the stone jacks from the pier")

# Wed, 01 Feb 2017 09:40:00

encrypted_message = use_key((13493, 149), message)

# Wed, 01 Feb 2017 09:40:07

encrypted_message

#[Out]#
'0462-11726-10454-9331-12338-0421-5619-0535-1963-0551-6070-1503-7638-4457-13221-13451-1
2497-13414-9719-10631'

# Wed, 01 Feb 2017 09:41:38

message=numerize("i am angry at neo because he is bullying me")

# Wed, 01 Feb 2017 09:41:58

encrypted_message = use_key(private_key, message)

# Wed, 01 Feb 2017 09:42:17

encrypted_message
#[Out]#
'7852-3095-1991-23155-15104-8224-4013-12532-9333-11069-17316-24106-21801-4341-19132-18
878-11069-15357-6311-19364-20249-16791'

# Wed, 01 Feb 2017 09:57:46

message

#[Out]#
'0679-0671-8306-7184-7788-9506-7190-0684-7585-0672-7573-7191-8975-0678-7506-7989-0672-9
182-8295-7984-7706-8375'

# Wed, 01 Feb 2017 09:58:03

message=numerize("i am angry at neo because he is bullying me")

# Wed, 01 Feb 2017 09:58:06

message

#[Out]#
'0679-0671-8306-7184-7788-9506-7190-0684-7585-0672-7573-7191-8975-0678-7506-7989-0672-9
182-8295-7984-7706-8375'

# Wed, 01 Feb 2017 10:02:31

decrypted_message =
use_key(private_key,3982-8206-4575-8480-7906-8682-7195-7588-8906-7188-7506-7475-7174-069
0-8506-8375)

# Wed, 01 Feb 2017 10:02:41

decrypted_message =
use_key(private_key,'3982-8206-4575-8480-7906-8682-7195-7588-8906-7188-7506-7475-7174-069
0-8506-8375')

# Wed, 01 Feb 2017 10:02:56

denumerize(decrypted_message

# Wed, 01 Feb 2017 10:03:05

decrypted_message

#[Out]#
'8008-11552-2401-17740-5588-11492-13114-21565-4630-1621-19132-10764-20813-7958-22507-1
6791'

# Wed, 01 Feb 2017 10:10:41


message=numerize("i am angry at neo because he is bullying me")

# Wed, 01 Feb 2017 10:11:03

encrypted_message = use_key(private_key, message)

# Wed, 01 Feb 2017 10:11:09

encrypted_message

#[Out]#
'7852-3095-1991-23155-15104-8224-4013-12532-9333-11069-17316-24106-21801-4341-19132-18
878-11069-15357-6311-19364-20249-16791'

# Wed, 01 Feb 2017 10:19:21

decrypted_message =
use_key(private_key,'3982-8206-4575-8480-7906-8682-7195-7588-8906-7188-7506-7475-7174-069
0-8506-8375')

# Wed, 01 Feb 2017 10:19:27

decrypted_message

#[Out]#
'8008-11552-2401-17740-5588-11492-13114-21565-4630-1621-19132-10764-20813-7958-22507-1
6791'

# Wed, 01 Feb 2017 10:19:38

denumerize(decrypted_message)

# Wed, 01 Feb 2017 10:20:03

denumerize(8008-11552-2401-17740-5588-11492-13114-21565-4630-1621-19132-10764-20813-79
58-22507-16791)

# Wed, 01 Feb 2017 10:20:10

denumerize('8008-11552-2401-17740-5588-11492-13114-21565-4630-1621-19132-10764-20813-79
58-22507-16791')

# Wed, 01 Feb 2017 10:20:54

decrypted_message =
use_key(private_key,'3982-8206-4575-8480-7906-8682-7195-7588-8906-7188-7506-7475-7174-069
0-8506-8375')

# Wed, 01 Feb 2017 10:21:00

denumerize(decrypted_message)
# Wed, 01 Feb 2017 10:21:36

plain_mess=decrypted_message

# Wed, 01 Feb 2017 10:21:44

denumerize(plain_mess)

# Wed, 01 Feb 2017 10:23:32

denumerize(3982-8206-4575-8480-7906-8682-7195-7588-8906-7188-7506-7475-7174-0690-8506-8
375)

# Wed, 01 Feb 2017 10:23:39

denumerize('3982-8206-4575-8480-7906-8682-7195-7588-8906-7188-7506-7475-7174-0690-8506-
8375')

#[Out]# 'All Genji players are dead to me'

6. (conclusion question #1). Explain the relationship among the following concepts.

The https:// designation in your browser


Means the browser is downloading an ssl certificate, with a public key in it
Public key encryption
A method of paired key encryption in which the key used for encryption is public and the decryption
key is secret
SSL certificate
SSL certificates are encrypted messages that confirm the key owner's identity and provide their
public key.
Certificate Authority
A business or organization that uses a digital certificate verifying that a given public key is owned by
the entity named on the certificate
Domain name
When a company gets an SSL certificate, they apply to a Certificate Authority (like Symantec) to
sign their certificate. The certificate authority uses their own private key to encrypt the applicant's
public key and the applicant's domain names

You might also like