Struct challenge_bypass_ristretto::voprf::UnblindedToken
source · #[repr(C)]pub struct UnblindedToken {
pub t: TokenPreimage,
W: CompressedRistretto,
}
Expand description
An UnblindedToken
is the result of unblinding a SignedToken
.
While both the client and server both “know” this value, it should nevertheless not be sent between the two.
Fields§
§t: TokenPreimage
t
is the TokenPreimage
W: CompressedRistretto
W
is the unblinded signed CompressedRistretto
point
\(W = Q^{1/r} = P^{k(1/r)} = T^{rk(1/r)} = T^k\)
Implementations§
source§impl UnblindedToken
impl UnblindedToken
sourcepub fn derive_verification_key<D>(&self) -> VerificationKey
pub fn derive_verification_key<D>(&self) -> VerificationKey
Derive the VerificationKey
for this particular UnblindedToken
fn bytes_length_error() -> TokenError
sourcepub fn from_bytes(bytes: &[u8]) -> Result<UnblindedToken, TokenError>
pub fn from_bytes(bytes: &[u8]) -> Result<UnblindedToken, TokenError>
Construct a UnblindedToken
from a slice of bytes.
Trait Implementations§
source§impl Clone for UnblindedToken
impl Clone for UnblindedToken
source§fn clone(&self) -> UnblindedToken
fn clone(&self) -> UnblindedToken
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl RefUnwindSafe for UnblindedToken
impl Send for UnblindedToken
impl Sync for UnblindedToken
impl Unpin for UnblindedToken
impl UnwindSafe for UnblindedToken
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more