Function: fromSignedOperation()
function fromSignedOperation(operation): SignedOperation;
Defined in: evm-client/src/utils.ts:377
Core's SignedOperation as the authorization envelope every *Signed
entry point takes.
Three fields go over the wire and two do not, which is the whole of the difference between how the two chains verify a delegated call:
expirywidens to the struct'suint64, unchanged in meaning.saltbecomesnonce. Core keys its replay guard on the raw 32 bytes and the contract on auint256, but they are the same bytes:intentDigestpacks the nonce withabi.encodePacked, i.e. big-endian, which is the orderslot(salt)writes it in the shared preimage. Reading the salt big-endian here is therefore not a choice — the two digests agree only if it is, and a byte-swapped nonce would fail asUnauthorizedSignerwith nothing to point at.signaturepasses through verbatim.signingKeyanddigestare dropped. Core recovers the signer from the signature (ECDSA.recover) and recomputes the digest itself, so neither is an input — and neither can be trusted as one, which is why the contract does not take them. Solana, having no ed25519 syscall, has to send both.
Parameters
| Parameter | Type |
|---|---|
operation | SignedOperation |
Returns
SignedOperation
Throws
when signature is not a recoverable secp256k1 signature. This is the
one wrong-curve case worth catching eagerly: core's own
OvercastProtocolSigner is ed25519, and an operation signed by it is a
perfectly well-formed SignedOperation that no EVM deployment can ever
verify. Its 64-byte signature would revert inside the recovery with
ECDSAInvalidSignatureLength — a submitted, gas-burning transaction, and a
confusing one, when the mistake is decidable from the length alone right here.