Low Private Exponent
Last updated
Last updated
Wiener Attack works when the private exponent is small. How small? If the private component satisfies:
then we can use Wiener's Attack to get the flag.
The idea behind Wiener's Attack is continued fraction. In the context of CTF, we don't need to worry about the underlying theory since this attack is already implemented in the package oWiener
. Install it with pip3 install owiener
. Read more about this implementation here:
Boneh-Durfee Attack also works when the private component is small, but it relaxes the restriction to another level compared to Wiener's Attack. If the private component satisfies:
then we can use Boneh-Durfee Attack to get the flag.
This attack is implemented in Sage. The code can be found here: