Re: Extract numbers from a key // wrong pgpdump link :-(

2011-08-24 Thread MFPA
-BEGIN PGP SIGNED MESSAGE- Hash: SHA512 Hi On Wednesday 24 August 2011 at 2:14:14 AM, in mid:4e545066.7040...@systemoverlord.com, David Tomaschik wrote: On 08/23/2011 06:52 PM, Faramir wrote: El 03-08-2011 9:40, ved...@nym.hush.com escribió: Sorry, wrong link extension, here is

Re: Extract numbers from a key // wrong pgpdump link :-(

2011-08-23 Thread Faramir
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 El 03-08-2011 9:40, ved...@nym.hush.com escribió: Sorry, wrong link extension, here is the correct one: http://www.pgpdump.net/ By the way, what would be required to run pgpdump locally? I guess there is no compiled version for windows...

Re: Extract numbers from a key // wrong pgpdump link :-(

2011-08-23 Thread David Tomaschik
On 08/23/2011 06:52 PM, Faramir wrote: El 03-08-2011 9:40, ved...@nym.hush.com escribió: Sorry, wrong link extension, here is the correct one: http://www.pgpdump.net/ By the way, what would be required to run pgpdump locally? I guess there is no compiled version for windows... Best

Re: Extract numbers from a key // wrong pgpdump link :-(

2011-08-23 Thread Robert J. Hansen
On 8/23/11 9:14 PM, David Tomaschik wrote: I don't see a windows binary, but it looks to be written in pure C with no external dependencies, so I would assume you could easily build it under Cygwin. Cygwin isn't necessary: it compiles just fine under plain MinGW. I've got a native Win32

Re: Extract numbers from a key

2011-08-19 Thread Peter Lebbing
On 17/08/11 17:16, ved...@nym.hush.com wrote: Here is a good overview (dated 1998, but not too many new RSA attack approaches since then:-) ) of 20 years of RSA attacks: http://crypto.stanford.edu/~dabo/abstracts/RSAattack-survey.html Thanks for the link! Peter. -- I use the GNU

Re: Extract numbers from a key

2011-08-15 Thread Peter Lebbing
On 14/08/11 16:39, Hubert Kario wrote: looking through full 512bit space will take 8192 less time than checking all numbers between 2^525 and 2^526. Or, equivalently, looking through full 512 bit space takes the same amount of time as checking all numbers between 2^513 and 2^514. It's exactly

Re: Extract numbers from a key

2011-08-14 Thread Peter Lebbing
On 04/08/11 17:14, Peter Lebbing wrote: On 03/08/11 12:43, Sébastien wrote: I know that gpg is an hybrid system. I want to know these numbers to check with a mathematica-like program that numbers supposed to be primes are actually real prime numbers. And suppose GnuPG accidentally picked

Re: Extract numbers from a key

2011-08-14 Thread Peter Lebbing
On 14/08/11 13:41, Hubert Kario wrote: From what I learned, RSA cracking is basically an exaustive search. If your prime is composite, it is at most half as long as a real prime would be. So, instead of a ~1024 bit prime you have a ~512 bit prime, which are tryvial to crack. Yes [1],

Re: Extract numbers from a key

2011-08-14 Thread Hubert Kario
On Sunday 14 August 2011 14:05:02 Peter Lebbing wrote: On 14/08/11 13:41, Hubert Kario wrote: From what I learned, RSA cracking is basically an exaustive search. If your prime is composite, it is at most half as long as a real prime would be. So, instead of a ~1024 bit prime you have a

Re: Extract numbers from a key

2011-08-04 Thread Sébastien
I know that gpg is an hybrid system. I want to know these numbers to check with a mathematica-like program that numbers supposed to be primes are actually real prime numbers. ___ Gnupg-users mailing list Gnupg-users@gnupg.org

Re: Extract numbers from a key

2011-08-04 Thread Sébastien
I tried the --with-key-data option which gives the numbers I'm looking for. Unfortunately, this doesn't work with the secret key. I tried with pgpdump but it doesn't work anymore because numbers in secret keys are encrypted. Is there any way to decrypt these numbers in the secret key? Le

Re: Extract numbers from a key

2011-08-04 Thread Jerome Baum
I know that gpg is an hybrid system. I want to know these numbers to check with a mathematica-like program that numbers supposed to be primes are actually real prime numbers. What is that supposed to tell you? It's not like Mathematica does an exhaustive check either. A healthy dose of

Re: Extract numbers from a key

2011-08-04 Thread Robert J. Hansen
On 8/4/11 9:05 AM, Jerome Baum wrote: What is that supposed to tell you? It's not like Mathematica does an exhaustive check either. The PRIMES algorithm can be expressed in Mathematica, and provides an exhaustive check. Mathematica's built-in tools don't provide PRIMES, but it can be added by

Re: Extract numbers from a key

2011-08-04 Thread Jerome Baum
The PRIMES algorithm can be expressed in Mathematica, and provides an exhaustive check.  Mathematica's built-in tools don't provide PRIMES, but it can be added by a modestly proficient Mathematica user. So just a sieve? Isn't that going to take ages on any reasonable key? -- Jerome Baum

Re: Extract numbers from a key

2011-08-04 Thread Robert J. Hansen
On 8/4/11 9:32 AM, Jerome Baum wrote: So just a sieve? Isn't that going to take ages on any reasonable key? No. http://en.wikipedia.org/wiki/AKS_primality_test ___ Gnupg-users mailing list Gnupg-users@gnupg.org

Re: Extract numbers from a key

2011-08-04 Thread Jerome Baum
Ah, I see why you referred to it as the PRIMES algorithm -- was mislead by a Google search on that string. Did you manage to get an unencrypted version of the private key? (Mobile/Handy) Am 04.08.2011 15:54 schrieb Robert J. Hansen r...@sixdemonbag.org: On 8/4/11 9:32 AM, Jerome Baum wrote:

Re: Extract numbers from a key

2011-08-04 Thread vedaal
Date: Wed, 03 Aug 2011 12:43:17 +0200 From: S?bastien tigresetdrag...@yahoo.fr Cc: gnupg-users@gnupg.org Subject: Re: Extract numbers from a key Message-ID: 4e392645.2020...@yahoo.fr Content-Type: text/plain; charset=UTF-8; format=flowed I know that gpg is an hybrid system. I want to know

Re: Extract numbers from a key

2011-08-04 Thread Robert J. Hansen
On 8/4/11 10:30 AM, Jerome Baum wrote: Ah, I see why you referred to it as the PRIMES algorithm -- was mislead by a Google search on that string. PRIMES isn't the name of an algorithm: PRIMES is the name of a problem in computer science. the PRIMES algorithm isn't the algorithm named PRIMES,

Re: Extract numbers from a key

2011-08-04 Thread Johan Wevers
On 04-08-2011 16:14, ved...@nym.hush.com wrote: All that is necessary, is to use pre-canned primes, (i.e. to generate a prime which falls within a range of primes stored in an offsite area by the implementation.) This would be fat to easy noticed by inspecting the sourcecode. If you just

Re: Extract numbers from a key

2011-08-04 Thread Peter Lebbing
On 03/08/11 12:43, Sébastien wrote: I know that gpg is an hybrid system. I want to know these numbers to check with a mathematica-like program that numbers supposed to be primes are actually real prime numbers. And suppose GnuPG accidentally picked a composite. What would be the security

Re: Extract numbers from a key

2011-08-04 Thread Peter Lebbing
On 04/08/11 17:11, Johan Wevers wrote: An even more subtle way to add a backdoor would be tampering with the RNG that creates the session keys and the factors in key generation. A bug such as this existed in the Unix version of pgp 5.0 and it took quite some time before it was found. Let's

Re: Extract numbers from a key

2011-08-04 Thread Sébastien
I success to catch the numbers with a blank passphrase and pgpdump. I found something strange with the number d. The operation e*d mod phi is not equal to 1, as expected with the RSA algo. I looked in cipher/rsa.c and I found that d is evaluated to match e*d mod f = 1 , with f =

Re: Extract numbers from a key

2011-08-04 Thread Peter Lebbing
Why is it coded like that ? Is it safe ? I'm pretty sure there is only one inverse given n and e, that is, d is unique. Accidentally choosing the wrong d because you made an algorithmic/programming error will create a non-working keypair. I'd say, since it works, it is correct. Perhaps the

Re: Extract numbers from a key

2011-08-04 Thread Peter Lebbing
On 04/08/11 20:30, Peter Lebbing wrote: Perhaps the better question is: *why* does it work? Why are the operations equivalent? H. Per the Handbook of Applied Cryptography 5th ed[1], section 8.5, computation of d can also be done modulo lambda, with lambda = lcm(p-1,q-1) =

Re: Extract numbers from a key

2011-08-04 Thread Werner Koch
On Thu, 4 Aug 2011 19:23, tigresetdrag...@yahoo.fr said: cipher/rsa.c and I found that d is evaluated to match e*d mod f = 1 , with f = phi/gcd((p-1),(q-1)) . Why is it coded like that ? Is it safe ? Using the universal exponent of n (lambda, in the code denoted as f) has the advantages that

Extract numbers from a key

2011-08-03 Thread Sébastien
Hello, I would like to know an easy way to get numbers used in a key. For example, in a RSA key, N and e (used like this: message^e modulus N) Here is one RSA 1024 bits public key: -BEGIN PGP PUBLIC KEY BLOCK- Version: GnuPG v1.4.10 (GNU/Linux)

Re: Extract numbers from a key

2011-08-03 Thread Melvin Carvalho
On 2 August 2011 20:10, Sébastien tigresetdrag...@yahoo.fr wrote: Hello, I would like to know an easy way to get numbers used in a key. For example, in a RSA key, N and e (used like this: message^e modulus N) Why do you want N and E? I think exponent is almost always 65537 Some apps display

Re: Extract numbers from a key

2011-08-03 Thread Jerome Baum
For example, in a RSA key, N and e (used like this: message^e modulus N) Note that gpg uses hybrid (session key) encryption. There are various advantages, e.g. you can reveal the session key to someone else (think subpoena) without giving up your entire key. -- Jerome Baum Hessenweg 222 48432

Re: Extract numbers from a key

2011-08-03 Thread Werner Koch
On Tue, 2 Aug 2011 20:10, tigresetdrag...@yahoo.fr said: I would like to know an easy way to get numbers used in a key. For example, in a RSA key, N and e (used like this: message^e modulus N) Import the key and then: $ gpg --list-keys --with-key-data KEYID In the output look for pkd

re: Extract numbers from a key // wrong pgpdump link :-(

2011-08-03 Thread vedaal
Sorry, wrong link extension, here is the correct one: http://www.pgpdump.net/ vedaal ___ Gnupg-users mailing list Gnupg-users@gnupg.org http://lists.gnupg.org/mailman/listinfo/gnupg-users