Module iop_keyvault::ed25519[][src]

SLIP-0010 compatible Ed25519 cryptography that allows child key derivation. There are alternative Ed25519-based implementations in other projects that are incompatible with SLIP-0010, so make sure this is the right derivation method for your use-case.

Structs

ChainCode

Chain code for key derivation in extended private and public keys. This is a 256-bit secret key that is completely independent of the private key and is used as an extension to the cryptographic domain, basically an extra state during iteration.

Ed25519

This elliptic curve cryptography implements both the AsymmetricCrypto and KeyDerivationCrypto traits so it can be used in EcDSA, Cardano and of course, Mopheus/Prometheus/Mercury.

EdExtPrivateKey

Implementation of Ed25519::ExtendedPrivateKey

EdKeyId

Implementation of Ed25519::KeyId

EdPrivateKey

Implementation of Ed25519::PrivateKey

EdPublicKey

Implementation of Ed25519::PublicKey

EdSignature

Implementation of Ed25519::Signature

Morpheus

Starting point for deriving all Morpheus related keys.

MorpheusKeyPath

A Morpheus path describing a position of a node in the HD wallet without being bound to a given seed. Will be useful for hardware wallet integrations in the future.

MorpheusKind

Root node of a specific kind of DIDs. The kind is invisible outside the wallet.

MorpheusKindAdmin

The admin node for a Morpheus kind node will be used for self-encrypting administrative data on a storage for the collection of identifiers of that kind.

MorpheusPrivateKey

The operations on an identifier that require the private key to be available in memory.

MorpheusPublicKey

The operations on an identifier that do not require the private key to be available in memory.

MorpheusRoot

Representation of the root node of the Morpheus subtree in the HD wallet.

MorpheusSubtree

Configuration of Bip32 key derivation for Morpheus.

MorpheusVaultAdmin

The admin node for the Morpheus root node will be used for self-encrypting administrative data on a storage for data not derived from the seed itself.

Enums

DidKind

There can be several usages of DIDs differentiated inside the wallet invisible externally, e.g. on a blockchain. Each represents a separate subtree under the Morpheus root node of the HD wallet.

Constants

CHAIN_CODE_SIZE

Size of the chain code in bytes

KEY_ID_SALT

This constant is used for keyed hashing of public keys. This does not improve the security of the hash algorithm, but allows for domain separation if some use-case requires a different hash of the public key with the same algorithm.

KEY_ID_SIZE

The size of the key identifier in bytes. Since a version byte is prepended to the hash result, it is not a standard size.

KEY_ID_VERSION1

The serialized byte representation for the current version of the hash algorithm applied on the public key to obtain the key identifier

PRIVATE_KEY_SIZE

The size of the private key in the format used by to_bytes

PUBLIC_KEY_SIZE

The size of the public key in the compressed format used by to_bytes

SIGNATURE_SIZE

Size of the signature is the version byte plus the actual Dalek Ed25519 signature size

SIGNATURE_VERSION1

The serialized byte representation for the current version of the signature algorithm (standard Ed25519 signature uses SHA256 internally and its output is only dependent on the private key and the message. It does not add an extra random keying that it could)

SLIP10_SEED_HASH_SALT

SLIP-0010 defines keyed hashing for master key derivation. This does domain separation for different cryptographic algorithms. This is the standard key for Ed25519

VERSION_SIZE

Since Wigy could not find any constant expression for the length of u8 in bytes (std::u8::LEN could be a good place), this is some manual trickery to define our “standard version byte length in bytes”