Skip to main content

Module key_ops

Module key_ops 

Source
Expand description

Curve-agnostic key operations.

Single source of truth for parsing, signing, and public key derivation across Ed25519 and P-256. The TypedSeed enum carries the curve with the key material — callers never need to guess which curve a key uses.

Structs§

ParsedKey
Parsed key material with curve baked in.
TypedSignerKey
Parsed signing key with curve carried explicitly — the authoritative owner of a private-key + curve pair across sign / verify / PKCS8 export / CESR encoding flows.

Enums§

TypedSeed
A private key seed that knows its curve.

Functions§

normalize_verkey
Normalize raw public key bytes to the canonical verkey form for curve.
parse_key_material
Parse any supported PKCS8 DER (or raw seed) to extract seed + public key + curve.
public_key
Derive the public key from the seed’s curve.
sign
Sign a message using the seed’s curve. No curve parameter needed.