pub struct Pair { /* private fields */ }
Expand description

A key pair.

Implementations

Get the seed for this key.

Exactly as from_string except that if no matches are found then, the the first 32 characters are taken (padded with spaces as necessary) and used as the MiniSecretKey.

Trait Implementations

Performs the conversion.

Performs the conversion.

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

The pair key type of this crypto.

Performs the conversion.

Performs the conversion.

Performs the conversion.

Generate new secure (random) key pair and provide the recovery phrase.

You can recover the same key later with from_phrase.

Generate key pair from given recovery phrase and password.

Make a new key pair from secret seed material.

You should never need to use this; generate(), generate_with_phrase

Make a new key pair from secret seed material. The slice must be 32 bytes long or it will return None.

You should never need to use this; generate(), generate_with_phrase

Derive a child key from a series of given junctions.

Get the public key.

Sign a message.

Verify a signature on a message. Returns true if the signature is good.

Verify a signature on a message. Returns true if the signature is good.

This doesn’t use the type system to ensure that sig and pubkey are the correct size. Use it only if you’re coming from byte buffers and need the speed.

Return a vec filled with raw data.

The type which is used to encode a public key.

The type used to (minimally) encode the data required to securely create a new key pair. Read more

The type used to represent a signature. Can be created from a key pair and a message and verified with the message and a public key. Read more

Error returned from the derive function.

Generate new secure (random) key pair. Read more

Interprets the string s in order to generate a key Pair. Returns both the pair and an optional seed, in the case that the pair can be expressed as a direct derivation from a seed (some cases, such as Sr25519 derivations with path components, cannot). Read more

Interprets the string s in order to generate a key pair. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Get a reference to the inner from the outer.

Get a mutable reference to the inner from the outer.

Should always be Self

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The counterpart to unchecked_from.