prototype of borrowing tmp structs & working gadget product with stacked rows

This commit is contained in:
Jean-Philippe Bossuat
2025-02-14 20:51:49 +01:00
parent e7a6ba17ee
commit fdc2f3ac42
11 changed files with 400 additions and 182 deletions

View File

@@ -1,8 +1,7 @@
use crate::ciphertext::GadgetCiphertext;
use crate::elem::Elem;
use crate::encryptor::{encrypt_rlwe_sk_thread_safe, encrypt_rlwe_sk_tmp_bytes};
use crate::parameters::Parameters;
use base2k::{Module, Scalar, SvpPPol, SvpPPolOps, VmpPMat, VmpPMatOps};
use base2k::{Module, Scalar, SvpPPol, SvpPPolOps, VecZnx};
use sampling::source::Source;
pub struct SecretKey(pub Scalar);
@@ -25,7 +24,7 @@ impl SecretKey {
}
}
pub struct PublicKey(pub Elem);
pub struct PublicKey(pub Elem<VecZnx>);
impl PublicKey {
pub fn new(module: &Module, log_base2k: usize, log_q: usize) -> PublicKey {