时间锁(proxy-locks) 约束Time Lock (proxy-locks) Constraints
来源:ckb-devrel/ckb-proxy-locks / contracts/time-lock/src/entry.rs · 0x6fac…4451 (data1,主网与测试网相同)Source: ckb-devrel/ckb-proxy-locks / contracts/time-lock/src/entry.rs · 0x6fac…4451 (data1, same on mainnet and testnet)
ckb-proxy-locks
- GitHubGitHubgithub.com/ckb-devrel/ckb-proxy-locks
来源:Source: repo (no website/docs listed)
A到期后由指定 lock 解锁Unlock by a given lock after a time
Inputs 输入Inputs
inputCell{ lock: { codeHash: TIME_LOCK, args: lock_hash 32B ‖ locked_until 8B } }, since ≥ locked_until
授权 cellauthorising cellCell{ lock: hash = lock_hash }
➜
Outputs 输出Outputs
outputs:任意outputs: any任意any
args 字节布局args byte layout
lock_hash32B
locked_until8B
- lock_hash 32B 所需 lock 脚本哈希required lock script hash 输入中存在present in inputs (7)
- locked_until 8B since 格式 u64 LEsince-encoded u64 LE 每个 group 输入 since 不小于它no group input since below it (6)
限制Constraints
- args ≥ 40 字节≥ 40 bytes (5)
- lock:: 输入中有 lock hash = args[0..32]an input has lock hash = args[0..32] (7)
- since:: 每个 group 输入 since 不小于 locked_until;ckb-std 比较时标志字节不同即不可比较,视为通过(按源码推断)every group input since is not below locked_until; with different flag bytes ckb-std cannot compare and it passes (inferred from source) (6)
部署与来源Deployments & source 未核验unverified
源码source ckb-devrel/ckb-proxy-locks@38b7e1df · contracts/time-lock/src/entry.rs (default-branch HEAD recorded at backfill 2026-10-21; spec/plugin were written from the default branch shortly before (exact read commit not recorded))
二进制核验binary check 未核验unverified no binary or checksum at the recorded commit matched the deployed data hash (reproducible build not attempted)
| 网络network | code_hash | cell_dep | type_id args | 数据哈希data hash | 部署交易deploy tx |
|---|---|---|---|---|---|
| mainnet | 0x6fac4b2e89360a1e692efcddcb3a28656d8446549fb83da6d896db8b714f4451 data1 | 0xb0ed754fb2…1ba0ac9b:1 code | — | 0x6fac4b2e89…714f4451 | 0xb0ed754fb2…1ba0ac9b #14221033 |
| testnet | 0x6fac4b2e89360a1e692efcddcb3a28656d8446549fb83da6d896db8b714f4451 data1 | 0x1b4ffcad55…dad90792:1 code | — | 0x6fac4b2e89…714f4451 | 0x1b4ffcad55…dad90792 #14831057 |
链上数据核对于 on-chain data checked 2026-10-20
错误码(error.rs):1 IndexOutOfBound · 2 ItemMissing · 3 LengthNotEnough · 4 Encoding · 5 InvalidArguments · 6 LockTimeNotPassed · 7 RequiredLockScriptNotFoundError codes (error.rs): 1 IndexOutOfBound · 2 ItemMissing · 3 LengthNotEnough · 4 Encoding · 5 InvalidArguments · 6 LockTimeNotPassed · 7 RequiredLockScriptNotFound
不检查任何签名:安全性完全来自 args 指向的其他脚本No signature is checked: security comes entirely from the script that args points to
不检查任何签名:安全性完全来自 args 指向的其他脚本No signature is checked: security comes entirely from the script that args points to