Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Richard Henderson
nettle
Commits
4f0ad31a
Commit
4f0ad31a
authored
Sep 13, 2018
by
Niels Möller
Browse files
rsa_generate_keypair: Delete unlikely and redundant check for p == q.
parent
cc57adbb
Changes
2
Show whitespace changes
Inline
Side-by-side
ChangeLog
View file @
4f0ad31a
2018-09-13 Niels Möller <nisse@lysator.liu.se>
* rsa-keygen.c (rsa_generate_keypair): Delete unlikely and
redundant check for p == q.
2018-08-09 Niels Möller <nisse@lysator.liu.se>
* rsa-internal.h (_rsa_blind, _rsa_unblind): Mark with
...
...
rsa-keygen.c
View file @
4f0ad31a
...
...
@@ -126,10 +126,6 @@ rsa_generate_keypair(struct rsa_public_key *pub,
random_ctx
,
random
,
progress_ctx
,
progress
);
/* Very unlikely. */
if
(
mpz_cmp
(
key
->
q
,
key
->
p
)
==
0
)
continue
;
mpz_sub_ui
(
q1
,
key
->
q
,
1
);
/* If e was given, we must choose q such that q-1 has no factors in
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment