Home GnuPG

cipher:kyber: Functions in poly for different KYBER_K.

Description

cipher:kyber: Functions in poly for different KYBER_K.

* cipher/kyber-common.c (load24_littleendian, cbd3): Fix the
compile-time condition.
(poly_cbd_eta1, poly_cbd_eta2): Remove.
(zetas): Don't export.
(poly_compress): Remove.
(poly_compress_128, poly_compress_160): New.
(poly_decompress): Remove.
(poly_decompress_128, poly_decompress_160): New.
(poly_getnoise_eta1): Remove.
(poly_getnoise_eta1_2): New.  Directly call cbd3.
(poly_getnoise_eta1_3_4): New.  Directly call cbd2.
(poly_getnoise_eta2):  Directly call cbd2.
* cipher/kyber.c: Fix declarations for poly_compress,
poly_decompress and poly_getnoise_eta1.
  • Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>

Details

Provenance
gniibeAuthored on Jan 15 2024, 3:11 AM
Parents
rC01a14c0df295: cipher:kyber: Make the implementation into three files.
Branches
Unknown
Tags
Unknown