Constant-time GCD function.
authorCesar Pereida Garcia <cesar.pereidagarcia@tut.fi>
Fri, 13 Sep 2019 14:54:54 +0000 (17:54 +0300)
committerNicola Tuveri <nic.tuv@gmail.com>
Thu, 17 Oct 2019 11:31:40 +0000 (14:31 +0300)
commitef599605040bc5c1a426ccd83d58cd0dd294509f
treeb29530c0578d297ce33324a66cfa2a7e3899e520
parentd63332a5f204195ed6922abf62a7ac7d0d0c7fd6
Constant-time GCD function.

This commit replaces the current `BN_gcd` function with a constant-time
GCD implementation.

(cherry picked from commit f3c4adfc7eb13e9eff514039b4c60b457bdba433)

Reviewed-by: Paul Dale <paul.dale@oracle.com>
Reviewed-by: Nicola Tuveri <nic.tuv@gmail.com>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/10122)
crypto/bn/bn_gcd.c