Skip to main content

Module keys

Module keys 

Source
Expand description

XRPL keys and signatures.

Two algorithms. An ed25519 key is 33 bytes, the first one 0xED; the message itself is signed. A secp256k1 key is a 33-byte compressed point, first byte 0x02 or 0x03; the SHA-512Half of the message is signed, and the signature is DER. This is what xrpld does (ripple::verify), and this is how we check.

secp256k1 canonicality: a validator that sets the “fully canonical signature” flag must produce a signature with low S. Without the flag xrpld also accepts high S, and so do we, normalizing it to low S: it is mathematically the same signature.

Enums§

KeyType
VerifyError

Constants§

NODE_PUBLIC
Version prefix for node and validator public keys: strings like n9….

Functions§

decode_base58
Base58Check decoding: version and payload, if the checksum matches.
encode_base58
Base58Check in the XRPL alphabet.
key_type
node_public
A validator public key as n9….
parse_node_public
A key from an n9… string.
verify
Checks signature sig over message with key pk.