Trait concrete_core::specification::engines::GlweCiphertextVectorDiscardingEncryptionEngine
source · [−]pub trait GlweCiphertextVectorDiscardingEncryptionEngine<SecretKey, PlaintextVector, CiphertextVector>: AbstractEnginewhere
SecretKey: GlweSecretKeyEntity,
PlaintextVector: PlaintextVectorEntity,
CiphertextVector: GlweCiphertextVectorEntity,{
fn discard_encrypt_glwe_ciphertext_vector(
&mut self,
key: &SecretKey,
output: &mut CiphertextVector,
input: &PlaintextVector,
noise: Variance
) -> Result<(), GlweCiphertextVectorDiscardingEncryptionError<Self::EngineError>>;
unsafe fn discard_encrypt_glwe_ciphertext_vector_unchecked(
&mut self,
key: &SecretKey,
output: &mut CiphertextVector,
input: &PlaintextVector,
noise: Variance
);
}
Expand description
A trait for engines encrypting (discarding) GLWE ciphertext vectors.
Semantics
This discarding operation fills the output
GLWE ciphertext vector
with the piece-wise encryptions of the input
plaintext vector, under the key
secret key.
Formal Definition
cf here
Required Methods
sourcefn discard_encrypt_glwe_ciphertext_vector(
&mut self,
key: &SecretKey,
output: &mut CiphertextVector,
input: &PlaintextVector,
noise: Variance
) -> Result<(), GlweCiphertextVectorDiscardingEncryptionError<Self::EngineError>>
fn discard_encrypt_glwe_ciphertext_vector(
&mut self,
key: &SecretKey,
output: &mut CiphertextVector,
input: &PlaintextVector,
noise: Variance
) -> Result<(), GlweCiphertextVectorDiscardingEncryptionError<Self::EngineError>>
Encrypts a GLWE ciphertext vector .
sourceunsafe fn discard_encrypt_glwe_ciphertext_vector_unchecked(
&mut self,
key: &SecretKey,
output: &mut CiphertextVector,
input: &PlaintextVector,
noise: Variance
)
unsafe fn discard_encrypt_glwe_ciphertext_vector_unchecked(
&mut self,
key: &SecretKey,
output: &mut CiphertextVector,
input: &PlaintextVector,
noise: Variance
)
Unsafely encrypts a GLWE ciphertext vector .
Safety
For the general safety concerns regarding this operation, refer to the different variants
of GlweCiphertextVectorDiscardingEncryptionError
. For safety concerns specific to an
engine, refer to the implementer safety section.
Implementors
impl GlweCiphertextVectorDiscardingEncryptionEngine<GlweSecretKey32, PlaintextVector32, GlweCiphertextVector32> for DefaultEngine
Description:
Implementation of GlweCiphertextVectorDiscardingEncryptionEngine
for DefaultEngine
that
operates on 32 bits integers.
impl GlweCiphertextVectorDiscardingEncryptionEngine<GlweSecretKey64, PlaintextVector64, GlweCiphertextVector64> for DefaultEngine
Description:
Implementation of GlweCiphertextVectorDiscardingEncryptionEngine
for DefaultEngine
that
operates on 64 bits integers.