Codebase list openssl / 8372efb
BN_copy now propagates BN_FLG_CONSTTIME Reviewed-by: Paul Dale <paul.dale@oracle.com> Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/4377) (cherry picked from commit 9f9442918aeaed5dc2442d81ab8d29fe3e1fb906) Samuel Weiser authored 6 years ago Matt Caswell committed 6 years ago
2 changed file(s) with 3 addition(s) and 2 deletion(s). Raw diff Collapse all Expand all
523523 memcpy(a->d, b->d, sizeof(b->d[0]) * b->top);
524524 #endif
525525
526 if (BN_get_flags(b, BN_FLG_CONSTTIME) != 0)
527 BN_set_flags(a, BN_FLG_CONSTTIME);
528
526529 a->top = b->top;
527530 a->neg = b->neg;
528531 bn_check_top(a);
381381 R = &(mont->RR); /* grab RR as a temp */
382382 if (!BN_copy(&(mont->N), mod))
383383 goto err; /* Set N */
384 if (BN_get_flags(mod, BN_FLG_CONSTTIME) != 0)
385 BN_set_flags(&(mont->N), BN_FLG_CONSTTIME);
386384 mont->N.neg = 0;
387385
388386 #ifdef MONT_WORD