projects
/
BearSSL
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fixed carry propagation bug in P-256 'm62' implementation (found by Auke Zeilstra...
[BearSSL]
/
src
/
rsa
/
rsa_i31_keygen_inner.c
diff --git
a/src/rsa/rsa_i31_keygen_inner.c
b/src/rsa/rsa_i31_keygen_inner.c
index
69120e7
..
98df445
100644
(file)
--- a/
src/rsa/rsa_i31_keygen_inner.c
+++ b/
src/rsa/rsa_i31_keygen_inner.c
@@
-340,9
+340,9
@@
mkprime(const br_prng_class **rng, uint32_t *x, uint32_t esize,
continue;
}
if ((pubexp == 3 && m3 == 1)
continue;
}
if ((pubexp == 3 && m3 == 1)
- || (pubexp == 5 && m5 ==
5
)
- || (pubexp == 7 && m
5 == 7
)
- || (pubexp == 11 && m
5 == 1
1))
+ || (pubexp == 5 && m5 ==
1
)
+ || (pubexp == 7 && m
7 == 1
)
+ || (pubexp == 11 && m
11 ==
1))
{
continue;
}
{
continue;
}
@@
-456,8
+456,8
@@
bufswap(void *b1, void *b2, size_t len)
/* see inner.h */
uint32_t
br_rsa_i31_keygen_inner(const br_prng_class **rng,
/* see inner.h */
uint32_t
br_rsa_i31_keygen_inner(const br_prng_class **rng,
- br_rsa_private_key *sk,
unsigned char
*kbuf_priv,
- br_rsa_public_key *pk,
unsigned char
*kbuf_pub,
+ br_rsa_private_key *sk,
void
*kbuf_priv,
+ br_rsa_public_key *pk,
void
*kbuf_pub,
unsigned size, uint32_t pubexp, br_i31_modpow_opt_type mp31)
{
uint32_t esize_p, esize_q;
unsigned size, uint32_t pubexp, br_i31_modpow_opt_type mp31)
{
uint32_t esize_p, esize_q;