[][src]Struct bbs::keys::DeterministicPublicKey

pub struct DeterministicPublicKey(_);

Used to deterministically generate all other generators given a commitment to a private key This is effectively a BLS signature public key

Implementations

impl DeterministicPublicKey[src]

pub fn to_bytes_compressed_form(&self) -> [u8; 96][src]

Convert to raw bytes compressed form

pub fn to_bytes_uncompressed_form(&self) -> [u8; 192][src]

Convert to raw bytes uncompressed form

impl DeterministicPublicKey[src]

pub fn new(option: Option<KeyGenOption>) -> (Self, SecretKey)[src]

Generates a random Secretkey and only creates the commitment to it

pub fn to_public_key(&self, message_count: usize) -> Result<PublicKey, BBSError>[src]

Convert to a normal public key but deterministically derive all the generators using the hash to curve algorithm BLS12381G1_XMD:SHA-256_SSWU_RO denoted as H2C h_0 <- H2C(w || I2OSP(0, 4) || I2OSP(0, 1) || I2OSP(message_count, 4)) h_i <- H2C(w || I2OSP(i, 4) || I2OSP(0, 1) || I2OSP(message_count, 4))

Trait Implementations

impl AsRef<G2> for DeterministicPublicKey[src]

impl Clone for DeterministicPublicKey[src]

impl Copy for DeterministicPublicKey[src]

impl Debug for DeterministicPublicKey[src]

impl Default for DeterministicPublicKey[src]

impl<'a> Deserialize<'a> for DeterministicPublicKey[src]

impl Display for DeterministicPublicKey[src]

impl Eq for DeterministicPublicKey[src]

impl<'_> From<&'_ [u8; 192]> for DeterministicPublicKey[src]

impl<'_> From<&'_ [u8; 96]> for DeterministicPublicKey[src]

impl<'_> From<&'_ G2> for DeterministicPublicKey[src]

impl From<[u8; 192]> for DeterministicPublicKey[src]

impl From<[u8; 96]> for DeterministicPublicKey[src]

impl From<Box<[u8]>> for DeterministicPublicKey[src]

impl From<G2> for DeterministicPublicKey[src]

impl HashElem for DeterministicPublicKey[src]

type Output = DeterministicPublicKey

The type that implements this trait

impl Into<Box<[u8]>> for DeterministicPublicKey[src]

impl PartialEq<DeterministicPublicKey> for DeterministicPublicKey[src]

impl Serialize for DeterministicPublicKey[src]

impl StructuralEq for DeterministicPublicKey[src]

impl StructuralPartialEq for DeterministicPublicKey[src]

impl<'_> TryFrom<&'_ [u8]> for DeterministicPublicKey[src]

type Error = BBSError

The type returned in the event of a conversion error.

impl TryFrom<Vec<u8>> for DeterministicPublicKey[src]

type Error = BBSError

The type returned in the event of a conversion error.

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,