Skip to main content

secp256k1_blake160_sighash_all

One of the CKB genesis Scripts, SECP256K1/blake160 (Source Code), is the default Lock Script used to verify transaction signatures on the CKB blockchain.

How It Works​

This Script uses the secp256k1 signature algorithm. The verification process includes:

  • Extracting the public key hash from the args field.
  • Constructing the signing message by hashing the tx_hash and the witnesses.
  • Reading the signature data from the lock witness.
  • Recovering the public key using secp256k1_ecdsa_recover.
  • Hashing the recovered public key using CKB's Blake2b algorithm, then taking the first 20 bytes.
  • Comparing the recovered public key hash to the one provided in args.

Reference RFC

Deployment​

  • Mainnet
parametervalue
code_hash0x9bd7e06f3ecf4be0f2fcd2188b23f1b9fcc88e5d4b65a8637b17723bbda3cce8
hash_typetype
tx_hash0x71a7ba8fc96349fea0ed3a5c47992e3b4084b031a42264a018e0072e8172e46c
index0x0
dep_typedep_group
  • Testnet
parametervalue
code_hash0x9bd7e06f3ecf4be0f2fcd2188b23f1b9fcc88e5d4b65a8637b17723bbda3cce8
hash_typetype
tx_hash0xf8de3bb47d055cdf460d93a2a6e1b05f7432f9777c8c474abf4eec1d4aee5d37
index0x0
dep_typedep_group