top | item 7578224 (no title) dogsky | 12 years ago Interesting. But from got the prime1 and prime2, from there how do you obtain the private certificate? discuss order hn newest alexkus|12 years ago You now know the two primes (p,q) which multiply together to make n (the public key modulus). We also know e (the public key exponent).d (the private key) is:- d = e^-1 mod ((p-1)(q-1)) To work this modular inverse out you use the extended Euclidean algorithm.This is why you need to know the factorisation of n=(p*q). You can't compute d (the private key) with just the composite n. cryptbe|12 years ago You don't need to use p or q. See http://vnhacker.blogspot.com/2014/04/idea-to-solve-cloudflar... load replies (2) benmmurphy|12 years ago i think this took me as long as coding the recovery tool :(https://github.com/jjarmoc/csaw2012_cert_app/blob/master/lib...https://github.com/ius/rsatool jjarmoc|12 years ago Yah, that's the trickiest part. I was pretty ecstatic when I found a real world use case for toy code that I spent way too much time on :) cryptbe|12 years ago I wrote a tool some time ago. It's 10 lines of Python using pyasn1.
alexkus|12 years ago You now know the two primes (p,q) which multiply together to make n (the public key modulus). We also know e (the public key exponent).d (the private key) is:- d = e^-1 mod ((p-1)(q-1)) To work this modular inverse out you use the extended Euclidean algorithm.This is why you need to know the factorisation of n=(p*q). You can't compute d (the private key) with just the composite n. cryptbe|12 years ago You don't need to use p or q. See http://vnhacker.blogspot.com/2014/04/idea-to-solve-cloudflar... load replies (2)
cryptbe|12 years ago You don't need to use p or q. See http://vnhacker.blogspot.com/2014/04/idea-to-solve-cloudflar... load replies (2)
benmmurphy|12 years ago i think this took me as long as coding the recovery tool :(https://github.com/jjarmoc/csaw2012_cert_app/blob/master/lib...https://github.com/ius/rsatool jjarmoc|12 years ago Yah, that's the trickiest part. I was pretty ecstatic when I found a real world use case for toy code that I spent way too much time on :) cryptbe|12 years ago I wrote a tool some time ago. It's 10 lines of Python using pyasn1.
jjarmoc|12 years ago Yah, that's the trickiest part. I was pretty ecstatic when I found a real world use case for toy code that I spent way too much time on :)
alexkus|12 years ago
d (the private key) is:-
To work this modular inverse out you use the extended Euclidean algorithm.This is why you need to know the factorisation of n=(p*q). You can't compute d (the private key) with just the composite n.
cryptbe|12 years ago
benmmurphy|12 years ago
https://github.com/jjarmoc/csaw2012_cert_app/blob/master/lib...
https://github.com/ius/rsatool
jjarmoc|12 years ago
cryptbe|12 years ago