# For Wednesday, Sept 27, 2022:

For Wednesday:

1. Please give me some anonymous course feedback.
2. Please compare last daily to the solutions here.
3. On the last daily post, you computed the square roots of $-1$ modulo $65$ using Sage.  Now compute them by hand using the Chinese Remainder Theorem (example in class and in the overleaf).  Make sure you get the same answers!
4. An RSA ciphertext chain!  We will use the #ciphertexts channel.
1. If you need a review of RSA, check the lecture notes, overleaf (where there’s an explicit example with Sage advice), video and textbook (Section 6.1 in 2nd edition).  For what follows, the Sage Sandbox page should be useful, as may be the RSA Tools page.  These pages show how to do operations like modular inverse, exponentiation, and euler phi function in Sage.  You can use Sage to do all your computations.
2. First, set up your public and private key.  Choose two 8-decimal-digit primes and form their product $n$.   Choose an encryption exponent $e$ that is positive and less than $\varphi(n)$.  Reveal your public key $n$ and $e$ on the discord #ciphertexts channel.  Compute your decryption exponent $d$ and keep it safe (along with $p$ and $q$) in a private file on your computer.  This is your private key information.
3. Create a secret message which is at most 6 letters long.  It should answer “What’s something awesome?”  Please don’t make it longer or this exercise won’t work.  Use only the 26 letters of the alphabet, but you can use lower or upper case.
4. Turn it into an integer using the Text to Integer tool.  (This turns it into an integer by writing the letters in ASCII and making an integer base 255 with those digits.  There’s an Integer-to-Text tool on the same page to undo this process.)
5. Now find someone else who has posted their public key, and encrypt your message to that person.  Post it on the #ciphertexts channel for them (use @theirname to alert them).
6. When someone posts a message for you, decrypt it and announce the result using discord’s “spoiler” feature (in case anyone else wants to compute the same plaintext).