mersenneforum.org How long to find RSA key ?
 Register FAQ Search Today's Posts Mark Forums Read

 2022-01-11, 20:46 #1 sega24     May 2013 148 Posts How long to find RSA key ? Hi :) Just a simply (maybe) question. I have a plain data and encrypted by rsa512 bit key. How long it can take, to find (brute force, step one by one) key ? I have i9 10980XE(18c36t) Factorise of 512bit takes almost 3days, but i dont want to factorise anything, just want to find right key :) Thanks ;)
 2022-01-11, 21:29 #2 Viliam Furik     "Viliam Furรญk" Jul 2018 Martin, Slovakia 75310 Posts I am not sure exactly how RSA512 works, and I am not willing to research it for this topic, but from what I know, it uses 512 bits as output. Thus it has 2^512 different possible outputs, which have 2^512 different possible inputs. That is about 1.340781e+154. If you could test 1,000,000,000,000,000 inputs (keys) per second, you would need about 4.251588e+131 YEARS to check them all. Assuming it would be randomly placed, you would most likely require about half of that or 2.125794e+131 YEARS. That would mean your poor CPU (and many other CPU slaves required for the total throughput of 1,000,000,000,000,000 inputs per second) would need to crunch for what is basically more than Googol of estimated ages of the universe (about 1.54043e+121 ages of the universe). 1.54043e+121 = 15,404,300,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000. This many ages of the universe. If its output is 512 bits in size, this should be about right. Otherwise, I am sorry, and I'll let others correct me.
 2022-01-11, 21:56 #3 sega24     May 2013 22·3 Posts No need to explain more :D thank you ;) my idea was bad :D
 2022-01-11, 22:24 #4 VBCurtis     "Curtis" Feb 2005 Riverside, CA 3·1,759 Posts Factoring the number is sufficient to break the key. Your first idea was the time it takes your machine to crack the key; how to use the factors is a matter of understanding the RSA encryption method- not too hard.
 2022-01-11, 22:35 #5 sega24     May 2013 22·3 Posts I dont want to break/crack or factorise any key. Just want to "know" the key. But the time how it takes, its to much for me :D
 2022-01-11, 22:46 #6 mathwiz   Mar 2019 32×29 Posts CADO-NFS can factor a 155 digit / 512 bit number in a few days, and that's only on a dual 8 core system: https://cado-nfs.gitlabpages.inria.fr/ If you have a 64-core machine (or a few) you can probably get that down to under a day.
 2022-01-12, 16:33 #7 chris2be8     Sep 2009 22·7·83 Posts I assume you know the 512 bit public key used to encrypt the data. To decrypt it you need the private key, which is the factors of (part of) the public key. That is a few days work on your PC. If you don't know the public key but do know the plain text and the cypher text it was encrypted into then finding the key used to encrypt is will be another matter. You should start by reading up on how the software used to encrypt it works. It may have stored the public key in the enrypted file, which is the easy case. If not check where ever the encrypted file came from to see if the key is somewhere you can find. If not then re-read how the software works for clues how to recover the key.
2022-01-12, 18:05   #8
xilman
Bamboozled!

"๐บ๐๐ท๐ท๐ญ"
May 2003
Down not across

101100000111002 Posts

Quote:
 Originally Posted by chris2be8 I assume you know the 512 bit public key used to encrypt the data. To decrypt it you need the private key, which is the factors of (part of) the public key. That is a few days work on your PC.
Strictly speaking the private key is derived* from (not is the factors of) the factors of the public modulus.

* That is currently the most computationally efficient way of finding the private key. Chequebook, rubberhose or blackbag attacks might be easier in practice.

 2022-01-12, 22:21 #9 sega24     May 2013 22×3 Posts chris2be8@ yes, i have only plain text (not all) and the cypher text. For example: plain text: 0101010101....(512bit)...010101 - not all bits i have cypher text: 5832412833...(512bit)...3231241 And yes, im looking private key, to decrypt cypher text. I cannot use GCD, beacouse i have only one example and its not full. The only thing what im sure is that is RSA PKCS v1. edit: and e is 65537 Last fiddled with by sega24 on 2022-01-12 at 22:42 Reason: added e
 2022-01-13, 16:35 #10 chris2be8     Sep 2009 1001000101002 Posts Where did the plaintext and cyphertext come from? Do you know what software was used to encrypt the plaintext to generate the cyphertext? Or what it did if it's not a standard product? Is this a puzzle someone set you? Or homework on a course? Start by reading up on RSA PKCS v1 in wikipedia etc. But you will need more details than that. Are the provided plaintext and cyphertext the same length? That would suggest it's been directly encrypted with 512 bit RSA (public key cryptography is much slower than symmetric cryptography so most programs would encrypt a file with something like AES256, then encrypt the secret key with the public key so the intended received can recover the secret key and decrypt the file. But the encrypted file would be a bit larger becasue of the encrypted key added as a header).

 Similar Threads Thread Thread Starter Forum Replies Last Post Stargate38 Programming 18 2015-07-10 06:08 topcat Hardware 17 2014-10-21 19:26 grandpascorpion Programming 7 2009-10-04 12:13 panic Hardware 9 2009-09-11 05:11 schickel Lounge 2 2009-02-22 12:31

All times are UTC. The time now is 07:21.

Wed May 18 07:21:00 UTC 2022 up 34 days, 5:22, 0 users, load averages: 0.66, 0.92, 1.11