You are on page 1of 4

Version 2022.

INFO23431: Assignment N1
Evaluation: 10 points, 10% of your final grade.
Due date: See SLATE.
Late submission: 10% per day penalty, up to 3 days.

Problem 1 (3 points).
In this problem you need to send an encrypted message to the course Instructor.
Download and Install Gpg4Win (use Default Options) https://gnupg.org/download/index.html
Mac Users: you can try GnuPG for OS X (but it has slightly different options).

Main Requirements:

1. Generate a personal Open PGP Key Pair (if you haven’t done so already in the class):
• Use your real full name and your official college @sheridancollege.ca e-mail address.
• Make sure your certificate does NOT expire.

2. You need to Import course Instructor’s public key. Please click on “Lookup on the Server”
and search for the key using course Instructor’s email.
For Dr. Alex Babanski’s class please use alex.babanski@sheridancollege.ca

Note: Anyone can submit a public key to the key


server using your name and e-mail address.
That’s why you must always verify the ID (Key-ID).
Dr. Alex Babanski’s ID: E9CA 3465 BE4B C932
Please ask your course instructor for correct ID.

© Sheridan College, Dr. Alex Babanski Page 1 of 4


INFO23431: Assignments N1 Winter 2022
Version 2022.3

3. You should also certify your course Instructor’s key locally.


Please do it only for yourself(!)

4. Use “Notepad” Icon to create an encrypted message

In the notepad write your full name and student ID.

5. Encrypt your message using course instructor’s certificate (public key).


Hint: you need to use “Encrypt for others” option. Do NOT Encrypt with your key or password!
Try encrypting a message using your classmate’s public key first and ask your classmate to
decrypt the message.

6. Copy the encrypted message and save it in the file problem1.txt.


You must upload it to the Dropbox. The file should look like:
-----BEGIN PGP MESSAGE-----

hQEMAw4xLK7LF4NTAQf/TsqOEWH7Nj70GZc7VN0QMGv6RQsbzU6cTPoe3iY7QCjO
hEWnrS7g5XvaiqQMn/TuFULykOBZzbWrbPYzR+rsE6GGp/hyGZyWHxkxwbxOnCwk
YpgVq4K+ttfqDBs6YJHtCYN+2szhjVHeL/bxSG9lV66CoUP8Q9B8s8r9L4jT0SOn
29AXi3C8TPKIKRuqRKkzjFdbM9PRNM/K06V9SYLWKvOYhLQ5Ir6qNmiPXKE41khh
Y/BctSUs7tBejT8vL49KrPmOt+m1PwRde2vVq09yHM1Vb34bL5QX+xORGFAjb3Ne
FJ70++hbl5wxVwwregsg7UWam1S+8DqJVBGLTP5HtNLAzQFN0Gxf4Wh1FgZOhDJG
KNSLn93v8TVo7bPKeGd7dsfBKZOElSVXJS/2f8WzwI+CT9xjSXML8fjN98+9kAiE
vkuQDt4K6JVuPjbX6hBlMq4GGVyBeLTNuQBfYR2G4LcVZY4GTHHC/TUL+EljtRz+
tIgm73RXgAJKdMim/0LMu+nu/hKtCz6LLkTHq0gG4OHgLUFj/VsZOVJWNJ7CfmOj
uuVj7F+cRWL38itrD0YSfmtugd4scD/lZwxqQlyJlnlpckyd3DRp5OQAWHlGFcqh
eiIqKZG5dYt/pHSQ51ipEqkIP6oUOJj4rJQ0Mzan5uuT1b63Nz2YB/yBWUxLbXh5
1hJr2ujdLLaYiGEUgY9M2khL98a4nrdmKax7FscL8+j4gKQBDJZydjZ8l3E3oa0/
oFvZbTEgmaWBX/X9B2KPyFUOdjsZ5U/43Ldl44g7bfjEtf1Im6CH+PnTGCkTgLTr
aBdTEOjpvUFoLp7K5OZE3O0nWYfTuznvXpiy//wK+NGUtXb9P5ZA/C7BFT15yKA=
=r5yp
-----END PGP MESSAGE-----

7. Publish your certificate on the server and provide a Key-ID of your certificate in the
comments. This step is required to verify your certificate.
Don’t forget to generate Revocation Certificate (right-click on your certificate -> Details).

You need to submit problem1.txt, and Key-ID of your certificate in the Dropbox comments.

© Sheridan College, Dr. Alex Babanski Page 2 of 4


INFO23431: Assignments N1 Winter 2022
Version 2022.3

Problem 2 (7 points).

In this problem you need to implement a special Vigenere cipher in C++. Your implementation must
be POSIX-compliant and should work with messages and secrets of any size, including messages
that have special characters, and any combination of upper- and lower-case letters.

Please check the full DEMO version here: https://youtu.be/y7sEP2StYa4

Main Requirements:
1. The program must be implemented using POSIX-compliant C++ (2014).
It’s strongly recommended to use CLion with Cygwin and the template file template.txt
2. Your implementation must match the Demo run (see the link above).
3. Your implementation must encrypt and decrypt messages using a special Vigenere cipher.
4. Your implementation must accept messages and secrets of any size (hint: use String class).
5. Your implementation must accept messages and secrets that have combination of upper-
and lower-case letters.
6. Your implementation must accept messages and secrets that have special symbols such as
digits, spaces, etc.
7. Your implementation should work with empty secrets.
8. Your implementation should have proper C++ programming techniques. Namely, use proper
data type, declare functions, avoid duplicate code, minimize time and space complexity, etc.

Hints:
• Check simple C++ implementation: https://www.geeksforgeeks.org/vigenere-cipher/
• Use getline() function in C++: getline(cin, plaintext) that also removes new line character.
• To get 3.5 points (50%) you need to implement at least a requirement 5, 6 or 7.

Submission Requirements:

This is an individual assignment. Even partially copied code will be subject to regulations against
academic integrity. Do NOT discuss or share your solution with anybody. Posting this assignment or
solution on the Internet is a violation of the Student Code of Conduct.

• Your submission must be two text files only: problem1.txt and problem2.txt
• In Problem N2 please save main.cpp as a text file problem2.txt with extension .txt
• You must upload problem1.txt and problem2.txt files to the Assignment Dropbox.
• For Problem N1, in the Dropbox comments please provide the Key-ID of your certificate.
• Your submission must be unique or have references.
• Late submissions are penalized 10% / day (1 point / day), up to 3 days.
Submissions won't be accepted after 3 days.

© Sheridan College, Dr. Alex Babanski Page 3 of 4


INFO23431: Assignments N1 Winter 2022
Version 2022.3

Grading Scheme:
• See Main requirements and also Course_Introduction.pdf.
Deductions will be applied if partial functionality is provided.

• You’ll get zero grade on your Problem N1 if the course instructor can’t decrypt your message.

• You’ll get zero grade on your Problem N2 if f your code doesn’t compile, or you simply copy
solution from the internet without adding extra functionality (see main requirements).

• You’ll get zero grade if you submit non-text files (.zip, .rar, .pdf, .doc, etc)

• Compilation warnings are considered to be major mistakes.

• Comments are not required but recommended. However, "debugging code" or commented
out "old code" is a minor mistake (unless it's clearly stated in the comments that you want me
to take a look at such code).

© Sheridan College, Dr. Alex Babanski Page 4 of 4


INFO23431: Assignments N1 Winter 2022

You might also like