[−][src]Struct safe_nd::NodeFullId
A struct holding an Ed25519 keypair, an optional BLS keypair share, and the corresponding public ID for a network Node.
Implementations
impl FullId
[src]
pub fn new<T: CryptoRng + Rng>(rng: &mut T) -> Self
[src]
Constructs a FullId
with a random Ed25519 keypair and no BLS keys.
pub fn within_range<T: CryptoRng + Rng>(
start: &XorName,
end: &XorName,
rng: &mut T
) -> Self
[src]
start: &XorName,
end: &XorName,
rng: &mut T
) -> Self
Constructs a FullId
whose name is in the interval [start, end] (both endpoints inclusive).
pub fn public_id(&self) -> &PublicId
[src]
Returns the public ID.
pub fn sign_using_ed25519<T: AsRef<[u8]>>(&self, data: T) -> Signature
[src]
Creates a detached Ed25519 signature of data
.
pub fn sign_using_bls<T: AsRef<[u8]>>(&self, data: T) -> Option<Signature>
[src]
Creates a detached BLS signature share of data
if the self
holds a BLS keypair share.
pub fn set_bls_keys(&mut self, bls_secret_key_share: BlsSecretKeyShare)
[src]
Sets the FullId
's BLS keypair share using the provided BLS secret key share.
pub fn clear_bls_keys(&mut self)
[src]
Clears the FullId
's BLS keypair share, i.e. sets it to None
.
Trait Implementations
impl<'de> Deserialize<'de> for FullId
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
impl Serialize for FullId
[src]
Auto Trait Implementations
impl RefUnwindSafe for FullId
impl Send for FullId
impl Sync for FullId
impl Unpin for FullId
impl UnwindSafe for FullId
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
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<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,