Home GnuPG

mpi: harden add_n_cond, sub_n_cond and abs_cond against EM leakage

Description

mpi: harden add_n_cond, sub_n_cond and abs_cond against EM leakage

* mpi/mpih-const-time.c (_gcry_mpih_add_n_cond)
(_gcry_mpih_sub_n_cond): Always perform calculation with both UP and
VP; Use two masks for selecting output.
(_gcry_mpih_abs_cond): Always calculate absolute value of UP; Use
two masks for selecting output.
  • GnuPG-bug-id: T5330
  • Signed-off-by: Jussi Kivilinna <jussi.kivilinna@iki.fi>

Details

Provenance
jukiviliAuthored on Apr 3 2021, 8:54 PM
Parents
rCc7c25b6e6e6b: mpi: harden set_cond functions against EM leakage
Branches
Unknown
Tags
Unknown
Tasks
Restricted Maniphest Task