SignaturePreAuthorized
Utilities for TIP-1165 pre-authorized access key signatures: a keychain signature bundled with the signed key authorization for its access key, so verifiers can accept it before the access key is registered onchain.
Functions
| Name | Description |
|---|---|
SignaturePreAuthorized.assert | Asserts that a value is a valid pre-authorized signature. |
SignaturePreAuthorized.from | Instantiates a TIP-1165 pre-authorized signature from its wrapped or unwrapped form. |
SignaturePreAuthorized.unwrap | Parses a TIP-1165 pre-authorized signature into its keychain signature and signed key authorization. |
SignaturePreAuthorized.validate | Validates a wrapped pre-authorized signature. Returns true if it decodes strictly, false otherwise. |
SignaturePreAuthorized.wrap | Serializes a TIP-1165 pre-authorized signature: rlp([keychain_signature, signed_key_authorization]) ‖ magic. |
Errors
| Name | Description |
|---|---|
SignaturePreAuthorized.InvalidUnwrappedSignatureError | Thrown when an unwrapped pre-authorized signature is malformed. |
SignaturePreAuthorized.InvalidWrappedSignatureError | Thrown when a wrapped pre-authorized signature is invalid. |
Types
| Name | Description |
|---|---|
SignaturePreAuthorized.Unwrapped | Unwrapped TIP-1165 pre-authorized signature. |
SignaturePreAuthorized.Wrapped | Wrapped TIP-1165 pre-authorized signature. |

