Skip to main content

Crate xrpl_mithril_wallet

Crate xrpl_mithril_wallet 

Source
Expand description

Key generation, signing, and address management for the XRPL.

This crate provides:

  • Key pair generation for secp256k1 (ECDSA) and Ed25519
  • Seed encoding/decoding (sXXX format)
  • Classic address and X-address conversion
  • Transaction signing (single-sign and multi-sign)

§Crypto Backends

By default, this crate uses pure-Rust cryptography:

  • k256 for secp256k1 ECDSA
  • ed25519-dalek for Ed25519

An optional native-crypto feature enables C-backed secp256k1 for environments where performance is critical.

§Quick Start

use xrpl_mithril_wallet::{Wallet, Algorithm};

// Generate a random Ed25519 wallet
let wallet = Wallet::generate(Algorithm::Ed25519).unwrap();
println!("Address: {}", wallet.classic_address());

Re-exports§

pub use algorithm::Algorithm;
pub use error::WalletError;
pub use keypair::Keypair;
pub use keypair::Wallet;
pub use seed::Seed;
pub use signer::sign;
pub use signer::multi_sign;
pub use signer::combine_signatures;
pub use signer::SignedTransaction;
pub use signer::Signer;

Modules§

address
Address derivation and X-address encoding.
algorithm
XRPL key algorithms and low-level cryptographic operations.
error
Error types for wallet operations.
keypair
Key pair and wallet types.
seed
XRPL seed encoding, decoding, and key derivation.
signer
Transaction signing for single-sign and multi-sign.