removed serialization of sealdata, instead created serializedsealdata struct which contains debugger info about cipher/plaintexts

This commit is contained in:
Matthew Liu
2023-07-19 13:30:00 -07:00
parent 38224850a7
commit 804275712c
3 changed files with 17 additions and 2 deletions

View File

@@ -0,0 +1,15 @@
use serde::{Serialize, Deserialize};
#[derive(Clone, Serialize, Deserialize)]
pub struct SerializedSealData {
value: i64,
data_type: SunscreenTypes,
noise_budget: f64,
coefficients: Vec<u64>,
multiplicative_depth: u64
}
#[derive(Clone, Serialize, Deserialize)]
pub enum SunscreenTypes {
}

View File

@@ -111,7 +111,7 @@ pub async fn get_fhe_node_data(
SealData::Ciphertext(ct) => {
let runtime = Runtime::new_fhe(&curr_session.private_key.0.params).unwrap();
runtime.decrypt()
runtime.decrypt(ct, &curr_session.private_key)
},
SealData::Plaintext(pt) => pt
};

View File

@@ -98,7 +98,7 @@ impl InnerPlaintext {
}
}
#[derive(Clone, Serialize, Deserialize)]
#[derive(Clone)]
/**
* A type that can be either a SEAL plaintext or a ciphertext.
*/