I was able to solve only one problem because I was swamped with research. I looked into lucky-roll-gaming with A1y and VinhChilling but we all did not have enough time to spend on it unfortunately. I think I should focus on learning how to solve chals fast by having some sort of a library (both in my brain and on my computer) of chals.
There were so many osu! references in this CTF that I could not understand because I am not a osu! player. Had I played osu! before, I might have enjoyed this CTF more. The competition website is here.
crypto/wysi-prime
Author: willwam
There was no challenge description, but it gives you two files: script.py and output.txt.
A typical RSA chal, except there is a hint about how $p$ and $q$ were chosen: they are both 272-digit prime numbers with every digit being either 2 or 7.
Whatever they are, they must be equal to $N$ when multiplied together, i.e. $N = pq$. This is too obvious to be mentioned here (?), but this also means we should have $N \equiv pq\; (\textrm{mod } 10)$, $N \equiv pq\; (\textrm{mod } 100)$, and so on. For instance, we can already figure out that the least significant digit $p$ and $q$ should be 7, because the least significant digit of $N$ is 9. More specifically, it is because $2 \times 2 = 4 \equiv 4 \; (\textrm{mod } 10)$, and $2 \times 7 = 14 \equiv 4 \; (\textrm{mod } 10)$, but $7 \times 7 = 49 \equiv 9 \; (\textrm{mod } 10)$.
All we need to do is to automate this process. There isn't much things I had to do, other than the fact that I needed a rookie reminder that variables in Python are references to objects in memory (I wasted an hour on that).
Interestingly, the first thing I tried was to see if I can brute force this. I tried to generate multiple 272-digit prime numbers that only had 2 and 7 for its digits, and see if any of them become $N$ when multiplied, but apparently this takes forever.