ethereum Sign Recoverable
Ethereum recoverable signature (FFI). Returns 65 bytes
r || s || v
, with v ∈ {27,28} (legacy/Electrum encoding where v = 27 + parity, parity ∈ {0,1}).
If
hashing == true
: signs per EIP-191 ("Ethereum Signed Message:\n{len(msg)}" || msg, then keccak256).If
hashing == false
:msg
must be a 32-byte prehash (e.g., keccak256/EIP-712 digest).Private key is automatically zeroized after signing for security