-
Notifications
You must be signed in to change notification settings - Fork 155
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(zk): Versionize ProvenCompactCiphertextList
- Loading branch information
1 parent
c1369d0
commit 2aac910
Showing
15 changed files
with
236 additions
and
65 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
use tfhe_versionable::{Unversionize, Versionize, VersionsDispatch}; | ||
|
||
use crate::curve_api::Curve; | ||
use crate::proofs::pke_v2::Proof; | ||
use crate::serialization::{ | ||
SerializableAffine, SerializableCubicExtField, SerializableFp, SerializableFp2, | ||
SerializableFp6, SerializableQuadExtField, | ||
}; | ||
|
||
#[derive(VersionsDispatch)] | ||
pub enum SerializableAffineVersions<F> { | ||
V0(SerializableAffine<F>), | ||
} | ||
|
||
#[derive(VersionsDispatch)] | ||
pub enum SerializableFpVersions { | ||
V0(SerializableFp), | ||
} | ||
|
||
#[derive(VersionsDispatch)] | ||
pub enum SerializableQuadExtFieldVersions<F> { | ||
V0(SerializableQuadExtField<F>), | ||
} | ||
|
||
#[derive(VersionsDispatch)] | ||
pub enum SerializableCubicExtFieldVersions<F> { | ||
V0(SerializableCubicExtField<F>), | ||
} | ||
|
||
pub type SerializableG1AffineVersions = SerializableAffineVersions<SerializableFp>; | ||
pub type SerializableG2AffineVersions = SerializableAffineVersions<SerializableFp2>; | ||
pub type SerializableFp12Versions = SerializableQuadExtFieldVersions<SerializableFp6>; | ||
|
||
#[derive(VersionsDispatch)] | ||
pub enum ProofVersions<G: Curve> | ||
where | ||
G::G1: Versionize + Unversionize, | ||
G::G2: Versionize + Unversionize, | ||
{ | ||
V0(Proof<G>), | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,4 +5,5 @@ pub mod curve_api; | |
pub mod proofs; | ||
pub mod serialization; | ||
|
||
pub mod backward_compatibility; | ||
mod four_squares; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.