In college I took MATH360 which was Mathematics of Information Security. In it we learned a lot of intro basics about cryptography and encryption. In class we were allowed to use anything we could code… thank goodness that was my major! Unfortunately, I struggled a bit trying to make methods and functions that would help me on the material when I first attempted to write the code in C++. We were dealing with such large numbers that 64 signed bits was not enough to represent them, and in C++ you must specify unsigned variables and then I had to make them of type Long Long (LL). Having ULL (unsigned long long) everywhere made for long and unreadable code, so I switched to the less verbose and more intuitive python. This worked 98% of the time. Only a few instances where my calculations, or the numbers we were dealing with, were still too big for my coding abilities and language experience.
Below is the code I used to answer many questions in MATH 360. It is somewhat long and messy because I had more important projects to complete. If I could redo it, I would have the system prompt the user for input asking which type of problem they wanted to solve and then what numbers they had in correspondence to which variables are needed. Instead, I used a switch statement to print out which problem I was working on and hard coded values and statements into each section to send numbers to a function. Some important functions available include zero-knowledge proofs, RSA encryption, what we called PowMod (Taking a number to a power and taking the modulus of it), Primality tests: Miller Rabbin, Solovoy-Strassen, Fermat Witness, and working with binary finite fields.
Sidenote: Due to number size constraints a few of these were done through sage on cocalc. This will be noted above the code highlighting What environment/language the code was done in.
Below is code that belongs to me that I used to help me on assignments, it was only turned in to show work and NOT for a grade. Again, this code was not assigned/required/or otherwise needed. The professor would even let us go over code together in class to do problems. They currently are not shown due to school and moral policy to not share code as a student. I will keep their descriptions available to understand what I have accomplished, but the code will not be released until either
It may be possible for you to request to see the code yourself as someone not attending CSU, looking to hire me, or a friend looking to satisfy your curiosity. Thank you for understanding :)