mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
(generate): Tweak to allow keys larger than 1024 bits. Enforce that the q
size doesn't end between byte boundaries.
This commit is contained in:
parent
2f94329422
commit
b625a6d1a9
2 changed files with 4 additions and 1 deletions
|
@ -180,8 +180,9 @@ generate( DSA_secret_key *sk, unsigned nbits, unsigned qbits,
|
|||
MPI h, e; /* helper */
|
||||
byte *rndbuf;
|
||||
|
||||
assert( nbits >= 512 && nbits <= 1024 );
|
||||
assert( nbits >= 512 );
|
||||
assert( qbits >= 160 );
|
||||
assert( qbits %8 == 0 );
|
||||
|
||||
p = generate_elg_prime( 1, nbits, qbits, NULL, ret_factors );
|
||||
/* get q out of factors */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue