全部经验 · CCC (TypeScript SDK) · 从这里开始 · 术语表
Building a remote CCC signer by extending SignerCkbPublicKey实践来自一次修复
来自一次修复 · 核对结果:部分正确 · 核对于 2026-11-19
To expose a remote secp256k1 key as a CCC signer, extend ccc.SignerCkbPublicKey(client, publicKey) and override signOnlyTransaction and signMessageRaw to call the backend. The address and lock come from the public key, and signMessageRaw must sign in the "Nervos Message:" format so signMessage and verifyMessage keep working. SignerCkbPublicKey also reports anyone-can-pay addresses of the key, whose cells a backend that only signs the secp256k1 lock cannot spend, so override getAddressObjs to return only the lock you can sign (ckb-keyway had to do this later).
为什么重要: If signMessageRaw signs in any other format, signatures from the remote signer fail CCC's verifyMessage even though the key is correct.
- 概念
- Witnesses and signatures
- 证据
- 来自一次修复: 来自一个项目,已对照其提交核对
- 首次出现
- 2026-10-12
- 最近改动
- 2026-10-12
- 最近核对
- 2026-11-19
- 对照提交的核对结果
- 部分正确:核心属实,但有一部分表述松散或范围过宽
来源(1)
- 2026-10-12 · officialcmg/ckb-keyway · 这个项目的更多经验
更多关于CCC (TypeScript SDK)
- Re-zero the witness lock before recomputing the sign message with getSignHashInfo
- Reserve co-signer witness space before completeFeeBy in multi-signer CCC transactions
- Adding a wallet missing from CCC's connector via a SignersController subclass
引用这条经验
LusoCryptoLabs, "Building a remote CCC signer by extending SignerCkbPublicKey", CKB lessons, https://pulse.lusocryptolabs.com/learned/ccc/building-a-remote-ccc-signer-by-extending-signerckbpublickey, CC BY 4.0, last changed 2026-10-12.