scicrypt_traits/lib.rs
1#![feature(trait_alias)]
2// These features are necessary to prevent the operator overloading for AssociatedCiphertext to clash between additive and multiplicative,
3// so we restrict the AssociatedCiphertext to never be a plaintext.
4#![feature(auto_traits, negative_impls)]
5#![warn(missing_docs, unused_imports)]
6
7//! _This is a part of **scicrypt**. For more information, head to the
8//! [scicrypt](https://crates.io/crates/scicrypt) crate homepage._
9//!
10//! General traits for cryptographic primitives in multi-party computation, such as homomorphic
11//! (threshold) cryptosystems, oblivious transfers (WIP), secret sharing, etc.
12
13/// Random number generation that is consistent with the dependencies' requirements.
14pub mod randomness;
15
16/// Concepts expressing the security level or setting of a given primitive or protocol.
17pub mod security;
18
19/// General notion of a cryptosystem
20pub mod cryptosystems;
21
22/// General notion of threshold cryptosystems
23pub mod threshold_cryptosystems;
24
25/// General notion of secret sharing
26pub mod secret_sharing;
27
28/// General error that arises when decryption fails, for example because there were not enough
29/// distinct decryption shares to decrypt a threshold ciphertext.
30#[derive(Debug)]
31pub struct DecryptionError;
32
33/// Homomorphic properties of homomorphic encryption schemes
34pub mod homomorphic;