Welcome to HBH! If you had an account on hellboundhacker.org you will need to reset your password using the Lost Password system before you will be able to login.

Little bit confused on this CTF Problem


pawnflow's Avatar
Member
0 0

I'm working on some CTFs right now and I'm stuck on this one problem. There were no write-ups so I'm gonna have to ask a favor from the HBH community. ** (Note: Ctf's done)**

Link: https://2016.pactf.com/static/ctfproblems/c0121378-93c3-459c-a8ea-133e0f155723/email-WTNk4Zn4ytCZ5fnr5Zyr.83e84e06b7ee.txt

Title: Mystery Man ** Description:** I’m Tony Tan, and I often get weird emails. But I don’t like the feels of this one, and I need to know who sent it. I want the sender’s first name, middle initial, and last name. Don’t email him though, because I don’t want him finding out about this.

What I know right now: "2048R/46726FC6" is a PGP public key. 0x03df93f346726fc6 is something in hex but when I convert it to ASCII, it's just gibberish. When I googled the PGP key, nothing came up.

Thanks in advance for the help.


gobzi's Avatar
Member
10 0

I assume that RSA is being used.

You have the public key which is n,e and you're looking for the private key which is n,d. I remember back in uni I had a very similar (if not the same) challenge, but honestly if you don't understand how RSA works they're is no way to solve that.

I would recommend you to watch: https://www.youtube.com/watch?v=kYasb426Yjk https://www.youtube.com/watch?v=EC9blllMYFg

Also you might want to read that:

https://people.csail.mit.edu/rivest/RivestKaliski-RSAProblem.pdf


pawnflow's Avatar
Member
0 0

But isn't it impossible to recover a private key with a public key?


gobzi's Avatar
Member
10 0

I'm not really good at explaining! Wiki has a great page explaining the problem.

https://en.wikipedia.org/wiki/RSA_problem

The most efficient method known to solve the RSA problem is by first factoring the modulus N, a task believed to be impractical if N is sufficiently large (see integer factorization). The RSA key setup routine already turns the public exponent e, with this prime factorization, into the private exponent d, and so exactly the same algorithm allows anyone who factors N to obtain the private key. Any C can then be decrypted with the private key.

Long story short if your 'n' is not large enough it is possible to get 'd'

Remember that your private key consists of d and n (which you already have in your public key)

http://slideplayer.com/slide/4994595/16/images/50/RSA+Key+Setup+each+user+generates+a+public/private+key+pair+by:.jpg

You may also want to read an ELI5 explanation https://www.reddit.com/r/explainlikeimfive/comments/5xy75k/eli5_what_makes_it_so_hard_to_factor_the_rsa/


Huitzilopochtli's Avatar
....
10 9

I've used Cryptool successfully for other RSA challenges before, if you have all the necessary info it can decode it for you in seconds. Use Cryptool 1 though, as apparently the newer versions, and their online portal is a little bit shit.


pawnflow's Avatar
Member
0 0

Ok, I'll try your guys' suggestions. Thanks for the help.