Struct rubble::ecdh::PublicKey[][src]

pub struct PublicKey(pub [u8; 64]);
Expand description

A P-256 public key (point on the curve) in uncompressed format.

The encoding is as specified in SEC 1: Elliptic Curve Cryptography, but without the leading 0x04 byte: The first 32 Bytes are the big-endian encoding of the point’s X coordinate, and the remaining 32 Bytes are the Y coordinate, encoded the same way.

Note that this type does not provide any validity guarantees (unlike PrivateKey implementors): It is possible to represent invalid public P-256 keys, such as the point at infinity, with this type. The other APIs in this module are designed to take that into account.

Tuple Fields

0: [u8; 64]

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

Performs the conversion.

Performs the conversion.

Should always be Self

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.