Official discussion thread for Rookie Mistake. Please do not post any spoilers or big hints.
God that last trap got me killing myself inside LOL
That being said, am I getting senile or should this work in Sage?
sage: discrete_log(Mod(23, 7 * 13), Mod(4, 7 * 13), ord=6 * 12)
ValueError: No discrete log of 23 found to base 4
whereas the answer should be 5? If you change ord to 6 (its real order) the same occurs.
Had to whip out my own implementation to get this to work.
Nice challenge @willwam845!
@ngoctnq This is indeed weird in my opinion. It does work for ord = 6, or without specifying an order in my case
sage: discrete_log(Mod(23, 7 * 13), Mod(4, 7 * 13), ord=6)
sage: discrete_log(Mod(23, 7 * 13), Mod(4, 7 * 13))
But as the doc states: ord - integer (multiple of order of base, or None), any multiple should work... but it doesn't...
ord - integer (multiple of order of base, or None)
@ArtemisFY Hey, thanks for the help with the other chall BTW, which version of Sage are you cranking? I tried both 9.1 and 9.2 through conda and both are bad. Guess I’ll file a bug report or something.
Edit: Weird. ord=6 (and consequently the code to solve this problem) works now on my machine. Can't trust anything these days.
So googling around, I got a way to reverse the second part of the flag but for the first part I'm at a bit of a loss. Is it similar to the second half decryption?
If what I said helped you you can always send some respects ^^
I really don't understand how to solve the first one since some important values are not co prime
@underc0very0 For the first part, I don't know if this is hinting too much but it's likely that the non-coprime part doesn't wrap around the modulus. And even if it does, there's an algorithm for it
Hope this hint helps Fukurou too.
I solved the first part very easily but stuck at the second part
I think for anyone stuck on the first part he can use some learning from cryptohack.org
i feel really shocked that most of you guys solving the second part before the first
I googled a lot but found nothing
hope someone drops a hint for the second part soon
Nice challenges @willwam845
Hint for second part: Chinese theories may help you.
Nice challenge @willwam845
The second part is definitely easier than the first. Google is your friend and plenty of hints already. If you are still stuck on the first part, here is my hint: DONT think about RSA, what would you do to unsquare a number?
I had to take a math course to solve this...
I have solved the DH part but I am really stuck on the RSA part. I think I have found what mathematics are required but I don't know how to use them to solve the problem...
Any nudge in pm would be appreciated!
Click here to create an account.