cryptography
Classes
| Class | Description |
|---|---|
| Signer | TODO: Document |
| Keypair | TODO: Document |
| PublicKey | A public key |
Interfaces
| Interface | Description |
|---|---|
| SignatureWithBytes | - |
Type Aliases
| Type Alias | Description |
|---|---|
| IntentScope | - |
| ParsedKeypair | - |
| SignatureScheme | - |
| SignatureFlag | - |
| SerializeSignatureInput | Pair of signature and corresponding public key |
Variables
| Variable | Description |
|---|---|
| PRIVATE_KEY_SIZE | - |
| LEGACY_PRIVATE_KEY_SIZE | - |
| IOTA_PRIVATE_KEY_PREFIX | - |
| SIGNATURE_SCHEME_TO_FLAG | - |
| SIGNATURE_SCHEME_TO_SIZE | - |
| SIGNATURE_FLAG_TO_SCHEME | - |
Functions
| Function | Description |
|---|---|
| messageWithIntent | Inserts a domain separator for a message that is being signed |
| decodeIotaPrivateKey | This returns an ParsedKeypair object based by validating the 33-byte Bech32 encoded string starting with iotaprivkey, and parse out the signature scheme and the private key in bytes. |
| encodeIotaPrivateKey | This returns a Bech32 encoded string starting with iotaprivkey, encoding 33-byte `flag |
| isValidHardenedPath | Parse and validate a path that is compliant to SLIP-0010 in form m/44'/4218'/{account_index}'/{change_index}'/{address_index}'. |
| isValidBIP32Path | Parse and validate a path that is compliant to BIP-32 in form m/54'/4218'/{account_index}'/{change_index}/{address_index} for Secp256k1 and m/74'/4218'/{account_index}'/{change_index}/{address_index} for Secp256r1. |
| mnemonicToSeed | Uses KDF to derive 64 bytes of key data from mnemonic with empty password. |
| mnemonicToSeedHex | Derive the seed in hex format from a 24-word mnemonic string. |
| toSerializedSignature | Takes in a signature, its associated signing scheme and a public key, then serializes this data |
| parseSerializedSignature | Decodes a serialized signature into its constituent components: the signature scheme, the actual signature, and the public key |