[−][src]Struct challenge_bypass_ristretto::dleq::DLEQProof
A DLEQProof
is a proof of the equivalence of the discrete logarithm between two pairs of points.
Fields
c: Scalar
c
is a Scalar
\(c=H_3(X,Y,P,Q,A,B)\)
s: Scalar
s
is a Scalar
\(s = (t - ck) \mod q\)
Methods
impl DLEQProof
[src]
fn _new<D, T>(
rng: &mut T,
P: RistrettoPoint,
Q: RistrettoPoint,
k: &SigningKey
) -> Result<Self, TokenError> where
D: Digest<OutputSize = U64> + Default,
T: Rng + CryptoRng,
[src]
rng: &mut T,
P: RistrettoPoint,
Q: RistrettoPoint,
k: &SigningKey
) -> Result<Self, TokenError> where
D: Digest<OutputSize = U64> + Default,
T: Rng + CryptoRng,
Construct a new DLEQProof
pub fn new<D, T>(
rng: &mut T,
blinded_token: &BlindedToken,
signed_token: &SignedToken,
k: &SigningKey
) -> Result<Self, TokenError> where
D: Digest<OutputSize = U64> + Default,
T: Rng + CryptoRng,
[src]
rng: &mut T,
blinded_token: &BlindedToken,
signed_token: &SignedToken,
k: &SigningKey
) -> Result<Self, TokenError> where
D: Digest<OutputSize = U64> + Default,
T: Rng + CryptoRng,
Construct a new DLEQProof
fn _verify<D>(
&self,
P: RistrettoPoint,
Q: RistrettoPoint,
public_key: &PublicKey
) -> Result<(), TokenError> where
D: Digest<OutputSize = U64> + Default,
[src]
&self,
P: RistrettoPoint,
Q: RistrettoPoint,
public_key: &PublicKey
) -> Result<(), TokenError> where
D: Digest<OutputSize = U64> + Default,
Verify the DLEQProof
pub fn verify<D>(
&self,
blinded_token: &BlindedToken,
signed_token: &SignedToken,
public_key: &PublicKey
) -> Result<(), TokenError> where
D: Digest<OutputSize = U64> + Default,
[src]
&self,
blinded_token: &BlindedToken,
signed_token: &SignedToken,
public_key: &PublicKey
) -> Result<(), TokenError> where
D: Digest<OutputSize = U64> + Default,
Verify the DLEQProof
impl DLEQProof
[src]
pub fn to_bytes(&self) -> [u8; 64]
[src]
Convert this DLEQProof
to a byte array.
fn bytes_length_error() -> TokenError
[src]
pub fn from_bytes(bytes: &[u8]) -> Result<DLEQProof, TokenError>
[src]
Construct a DLEQProof
from a slice of bytes.
Auto Trait Implementations
Blanket Implementations
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Same for T
type Output = T
Should always be Self