Table of Contents
HackTheBox - Challenge - Crypto - Weak RSA
The HTB “Weak RSA” Crypto is an easy challenge based on the RSA cipher.
You are provided with the following files:
At first glance, you’d think you can decrypt the flag with the public key.
For that, we might use the OpenSSL package to decrypt the flag. This time it’s a bit different and you’ll find that the OpenSSL package won’t work for this challenge.
We’ll use an automated RSA attack tool. A common python script is the RsaCtfTool
python3 RsaCtfTool.py --publickey ./key.pub --uncipherfile ./flag.enc
Simply put, this tool finds the flag easily for you in an automated fashion.