EVM Contract Types
This page documents the data types used in the Signet EVM Contract.
SignRequest
Request structure for initiating a signature via sign.
struct SignRequest {
bytes32 payload;
string path;
uint32 keyVersion;
string algo;
string dest;
string params;
}Fields
| Field | Type | Description |
|---|---|---|
payload | bytes32 | 32-byte data to be signed (typically a hash) |
path | string | Derivation path for the signing key |
keyVersion | uint32 | Version of the MPC key to use |
algo | string | Signing algorithm (optional, default: secp256k1) |
dest | string | Response destination chain (optional) |
params | string | Additional parameters as JSON (optional) |
Response
Response structure containing a signature for a request.
struct Response {
bytes32 requestId;
Signature signature;
}Fields
| Field | Type | Description |
|---|---|---|
requestId | bytes32 | Identifier of the original request |
signature | Signature | ECDSA signature for the request |
Signature
ECDSA signature structure returned by the MPC network.
struct Signature {
AffinePoint bigR;
uint256 s;
uint8 recoveryId;
}Fields
| Field | Type | Description |
|---|---|---|
bigR | AffinePoint | R point of the ECDSA signature |
s | uint256 | s scalar of the signature |
recoveryId | uint8 | Recovery ID for public key recovery (0 or 1) |
AffinePoint
Represents a point on the secp256k1 elliptic curve.
struct AffinePoint {
uint256 x;
uint256 y;
}Fields
| Field | Type | Description |
|---|---|---|
x | uint256 | x coordinate of the point |
y | uint256 | y coordinate of the point |
Notes
- For the signature's R point,
xis typically used as thervalue in RSV format
