Description
Purpose
The purpose of this assignment is to familiarize you more with Python (or the programming language
you choose) and writing a simple decryption function for a custom encryption routine. You will learn
how to read encryption code, derive the corresponding decryption function (which is the inverse
function of the encryption function), implement the decryption function, and apply the decryption
function on a given input string.
Objectives
Learners will be able to:
● Read the encryption implementation of the Esper cipher.
● Implement an individual decryption function for an Esper cipher.
● Deal with files and bytes programmatically.
● Decrypt a given ciphertext that is encrypted using an Esper cipher and its corresponding key.
Technology Requirements
The reference encryption code is provided as a Python script; however, you may implement your
solutions in any programming language that you choose.
Note: The course team will not be able to help you if you choose any language that is not Python,
Java, or C#; therefore, to create the best learning experience, Python is strongly recommended.
Assignment Description and Directions
Technology Setup Reminder
If you have not already joined the course’s pwn.college, please review the setup directions in Module
0: Welcome and Start Here of your course to properly gain access and start your work.
CSE 543
Esper Cipher Assignment 1
Accessing the Environment
1. Navigate to https://pwn.college.
2. Click “Login” in the upper right corner of the screen and enter your account credentials.
a. Click “Forgot your password?” if you have trouble logging in.
3. Navigate to “Dojos”, second option from the left at the top of the screen.
4. Under “Courses”, select “CSE 543 – Session X Year”.
5. Under “Modules”, select “Esper Cipher Assignment”.
6. Under “Challenges”, click on “Esper Cipher”, read the details, and then click “Start” when you
are ready to work.
a. Optional: use “Practice” to help you work through the level with assistance.
Assignment Directions
Esper cipher is a custom cipher. Unlike Caesar cipher that works on uppercase English alphabet only,
Esper cipher works on bytes. You will not find its implementation anywhere else. The only reference
you have is `esper.py` that implements the Esper cipher.
For this assignment, you are provided with three files:
1. `ciphertext.txt` – A ciphertext encrypted with an Esper cipher.
2. `esperkey.txt` – The key used for the Esper cipher. It is the stdout output when running
`esper.py` to encrypt the plaintext.
3. `esper.py` – The reference implementation of the Esper cipher with only the encryption feature.
You will need to write some code so you can plug in the key (as specified in `esperkey.txt`) and
decrypt the ciphertext in `ciphertext.txt`. You will only submit the plain text `plaintext.txt` to
/challenge/challenge.py. Do not include the ciphertext as part of your submission.
If your decryption works correctly, you will see multiple meaningful sentences in English as the
plaintext. Otherwise please go back and fix your implementation.
Here are some recommended steps to solve this problem:
1. Read `esper.py` to understand the encryption algorithm.
2. Write down the encryption algorithm on a piece of paper.
3. Invert the encryption algorithm to get the decryption algorithm.
CSE 543
Esper Cipher Assignment 2
4. Implement the decryption algorithm in the programming language that you like. Python is
recommended.
5. Use the implemented decryption algorithm to decrypt the ciphertext in `ciphertext.txt`.
Submission Directions for Assignment Deliverables
You are given an unlimited number of attempts to submit your best work. The number of attempts is
given to anticipate any submission errors you may have in regards to properly submitting your best
work within the deadline (e.g., accidentally submitting the wrong paper). It is not meant for you to
receive multiple rounds of feedback and then one (1) final submission. Only your most recent
submission will be assessed.
You must complete your Esper Cipher Assignment deliverables in pwn.college and then submit the
deliverables in its submission space in the course. Carefully review submission directions
outlined in the overview document in order to correctly earn credit for your work. Learners may not
email or use other means to submit any assignment or project for review, including feedback, and
grading.
The Esper Cipher Assignment includes three (3) deliverables submitted as one (1) ZIP file:
● Program/Code: Please include the code you have written for the assignment.
● Decrypted Message: Attach the decrypted message you obtained from your code, saved as a
.txt file.
● Solution Write-up: Provide a write-up detailing how you solved the assignment problem. This
should also be saved as a .txt file.
Do not include your name, your ID number, or the ciphertext as part of your submission.
Making File Submissions in Canvas
Before submitting, confirm that your deliverables follow the requirements for the project, and then
submit your work in the designated submission space in the course. Your submission will be reviewed
by the course team before finalizing your assignment grade.
1. In your course, go to Submission: Esper Cipher Assignment.
2. Click Start Assignment.
CSE 543
Esper Cipher Assignment 3
3. Click Choose File.
4. Locate and select one (1) deliverable file from your device.
5. If needed, click +Add Another File and repeat Steps 3 and 4 until all deliverables are added.
6. Select the agreement and then click Submit Assignment.
7. (If needed and allowed) To resubmit files:
a. Return to the Canvas submission space, click New Attempt, and repeat the process
from Step 3.
Evaluation
Your submission will be automatically graded in the challenge environment. As you complete each
challenge, you will receive a score in pwn.college. Scores will automatically populate to the course
after completion or after the due date passes. You will earn the maximum number of points for the
corresponding assignment in Canvas if you earn 100% on the challenge in pwn.college. Please refer
to the Course Grade Breakdown in the syllabus PDF and the assignment submission space in
Canvas so you know how many points each assignment is worth.
Your deliverables will be reviewed by the course team before finalizing your assignment grade. No
credit will be given for missing or incorrect submissions.
Review the course syllabus for details regarding late penalties.
● You will earn full credit if your submitted plain text is fully correct.
● If your submitted plain text is not correct, you will not earn credit.
● Partial credit will not be granted for this assignment.

