Struct dusk_pki::ViewKey [−][src]
pub struct ViewKey { /* fields omitted */ }
Pair of a secret a
and public b·G
The notes are encrypted against secret a, so this is used to decrypt the blinding factor and value
Implementations
impl ViewKey
[src]
impl ViewKey
[src]pub fn new(a: JubJubScalar, B: JubJubExtended) -> Self
[src]
This method is used to construct a new ViewKey
from the given
pair of secret a
and public b·G
.
pub fn public_spend_key(&self) -> PublicSpendKey
[src]
Derive the secret to deterministically construct a PublicSpendKey
pub fn a(&self) -> &JubJubScalar
[src]
Gets a
pub fn B(&self) -> &JubJubExtended
[src]
Gets B
(b·G
)
pub fn owns(&self, owner: &impl Ownable) -> bool
[src]
Checks PKr = H(R · a) · G + B
Trait Implementations
impl From<&'_ SecretSpendKey> for ViewKey
[src]
impl From<&'_ SecretSpendKey> for ViewKey
[src]fn from(secret: &SecretSpendKey) -> Self
[src]
impl From<SecretSpendKey> for ViewKey
[src]
impl From<SecretSpendKey> for ViewKey
[src]fn from(secret: SecretSpendKey) -> Self
[src]
impl Serializable<64_usize> for ViewKey
[src]
impl Serializable<64_usize> for ViewKey
[src]Auto Trait Implementations
impl RefUnwindSafe for ViewKey
impl RefUnwindSafe for ViewKey
impl UnwindSafe for ViewKey
impl UnwindSafe for ViewKey
Blanket Implementations
impl<T, const N: usize> DeserializableSlice<N> for T where
T: Serializable<N>,
[src]
impl<T, const N: usize> DeserializableSlice<N> for T where
T: Serializable<N>,
[src]impl<T, const N: usize> ParseHexStr<N> for T where
T: Serializable<N>,
[src]
impl<T, const N: usize> ParseHexStr<N> for T where
T: Serializable<N>,
[src]pub fn from_hex_str(s: &str) -> Result<Self, Self::Error> where
Self::Error: BadLength,
Self::Error: InvalidChar,
[src]
Self::Error: BadLength,
Self::Error: InvalidChar,