Move Serde De/Serialization to Group Implementation (#380)
* Move Serde De/Serialization to `Group` implementation * Clean up Serde formats * Fix typo
This commit is contained in:
+8
-2
@@ -58,7 +58,10 @@ pub struct RegistrationRequest<CS: CipherSuite> {
|
||||
#[cfg_attr(
|
||||
feature = "serde",
|
||||
derive(serde::Deserialize, serde::Serialize),
|
||||
serde(bound = "")
|
||||
serde(bound(
|
||||
deserialize = "<KeGroup<CS> as Group>::Pk: serde::Deserialize<'de>",
|
||||
serialize = "<KeGroup<CS> as Group>::Pk: serde::Serialize"
|
||||
))
|
||||
)]
|
||||
#[derive_where(Clone)]
|
||||
#[derive_where(Debug, Eq, Hash, Ord, PartialEq, PartialOrd; voprf::EvaluationElement<CS::OprfCs>, <KeGroup<CS> as Group>::Pk)]
|
||||
@@ -74,7 +77,10 @@ pub struct RegistrationResponse<CS: CipherSuite> {
|
||||
#[cfg_attr(
|
||||
feature = "serde",
|
||||
derive(serde::Deserialize, serde::Serialize),
|
||||
serde(bound = "")
|
||||
serde(bound(
|
||||
deserialize = "<KeGroup<CS> as Group>::Pk: serde::Deserialize<'de>",
|
||||
serialize = "<KeGroup<CS> as Group>::Pk: serde::Serialize"
|
||||
))
|
||||
)]
|
||||
#[derive_where(Clone, ZeroizeOnDrop)]
|
||||
#[derive_where(Debug, Eq, Hash, Ord, PartialEq, PartialOrd; <KeGroup<CS> as Group>::Pk)]
|
||||
|
||||
Reference in New Issue
Block a user