{"id":"XE-0066","kind":"bounty","visibility":"public","source":"github","source_repo":"xeprotocol/xe","source_ref":"91","source_url":"https://github.com/xeprotocol/xe/issues/91","reporter_id":2867,"title":"[Statechain Governance] Single oracle key can future-timestamp a block to early-activate and permanently freeze feature activations (no DAO threshold, no timestamp upper bound)","area":"consensus","claimed_tier":"high","assessed_tier":null,"verdict":"duplicate","duplicate_of":"XE-0037","tracked":true,"internal_ref":"#870","internal_url":"https://github.com/xeprotocol/core/issues/870","status":"closed","closed_reason":"duplicate","github_state":"closed","disclosed_at":null,"award_xe":null,"award_approved":false,"paid_ref":"","created_at":"2026-10-29T13:57:20.058210+00:00","updated_at":"2026-11-16T13:42:49.539255+00:00","source_created_at":"2026-10-26T21:51:54+00:00","told_at":"2026-11-08T08:46:23+00:00","status_changed_at":"2026-10-29T14:22:09.932555+00:00","url":"https://bounty.xe.network/XE-0066","body":"Suggested severity: High (10,000 XE).\n\n## Summary\n\nStatechain oracle-path blocks (all ops under the oracle's allowed prefix, e.g. `epoch.`, requiring only the oracle threshold — 1 key in the testnet-0005 genesis) have no timestamp upper bound or skew check: the only timestamp check in `statechain/chain.go:148` rejects timestamps that go backwards. `FeatureActive()` uses the tip timestamp, and `statechain/activations.go` freezes the trigger of any feature once it becomes active (it can no longer be changed or removed).\n\n## Impact\n\nOne oracle key can publish a block timestamped years in the future and instantly activate every feature gated by `NotBeforeNS`, bypassing the DAO threshold (2-of-3) entirely. Once active, the trigger is frozen, so the DAO cannot undo or delay the activation. As a side effect, all subsequent blocks must carry timestamps >= the fake time, since timestamps are monotonic against the tip.\n\n## Steps to Reproduce (local, no real funds)\n\n1. Build a statechain with the testnet-0005-style config: oracle = 1 key, threshold 1, allowed prefix `epoch.`; DAO = 2-of-3; one feature gated by `at_index=1, not_before_ns = now + 5 years`.\n2. Observe the feature is NOT active at genesis.\n3. Submit one oracle-signed block (index 1) with Timestamp = now + 6 years containing a valid epoch op.\n4. Observed: the block is accepted and the feature becomes active immediately, with no DAO involvement.\n5. Submit a DAO-signed block (2-of-3) attempting to remove the feature trigger. Observed: rejected (\"activations are one-directional\") — the early activation is permanent.\n\n## Recommendation\n\nEnforce a timestamp upper bound / skew window on statechain blocks (e.g. reject timestamps more than N minutes ahead of wall time, as the ledger does for attestations), and/or require DAO threshold for blocks whose timestamp would activate features.\n\nHonest caveat: this applies to the testnet-0005 genesis configuration (oracle threshold 1). If mainnet changes the oracle threshold, severity changes with it. The oracle is a trusted role, but threshold-1 plus no time bound is the combination that gives one key governance power over activation timing.\n\nPayout address: to be provided on request.","patch_refs":[{"id":132,"repo":"xeprotocol/xe","kind":"pr","ref":"112","title":"fix(statechain): reject future-timestamped blocks and gate feature activations on DAO threshold (#91)","url":"https://github.com/xeprotocol/xe/pull/112","note":"","state":"open","author":"arturbarszcz78","added_by":"desk","created_at":"2026-10-29T13:57:30.091343+00:00"}],"thread":[{"id":789,"source":"github","source_ref":"6719432479","author":"Joseph Denne","team":true,"body":"Thanks. This is the same finding as #58, which was filed first: no upper bound on statechain block timestamps, so the 1-of-1 oracle key can jump governance activations. #58 is accepted; the programme pays the first verifiable submission, so this one closes as a duplicate. If you believe it is a different bug, reply with what differs and we will look again.","created_at":"2026-11-08T08:46:23+00:00"}]}