Home GnuPG

mpih-const-time: use constant-time comparisons conditional add/sub/abs
74588de441fdUnpublished

Unpublished Commit · Learn More

Not On Permanent Ref: This commit is not an ancestor of any permanent ref.

Description

mpih-const-time: use constant-time comparisons conditional add/sub/abs

* mpi/mpih-const-time.c (mpih_ct_limb_greater_than)
(mpih_ct_limb_less_than): New.
(_gcry_mpih_add_n_cond, _gcry_mpih_sub_n_cond, _gcry_mpih_abs_cond): Use
mpih_ct_limb_greater_than and mpih_ct_limb_less_than for comparisons.

Cherry pick master commit of:
c419a04d529af7b5fb43732ec2b4304166c2579a

  • Signed-off-by: Jussi Kivilinna <jussi.kivilinna@iki.fi>

Details

Provenance
jukiviliAuthored on Nov 2 2023, 7:59 PM
gniibeCommitted on Nov 7 2023, 1:34 AM
Parents
rC01e7052cb245: const-time: add functions for generating masks from 0/1 input
Branches
Unknown
Tags
Unknown

Event Timeline