Bounty
XE-13381 · Bounty

[DAO] resolutions.propose and portal.decide allow direction-inverted, ops-mismatched, concurrent-withdrawal, and cancelled-session open-vote decisions

Closed · duplicate — xe#538 filed 2026-11-13 06:10 UTC by Khanhtnq

Report

Summary

Across dao/services/resolutions.py (propose) and dao/services/portal.py (_decision_resolution, decide), open-vote resolutions (adopt_open_vote, decline_open_vote) and proposal decisions (adopt, decline, refer, defer) fail to enforce agreement on target proposal, direction, operations (ops), concurrent withdrawal locking, and linked signing-session liveness:

  1. Unbound or dead-on-arrival open-vote resolutions at intake (resolutions.propose):
    • adopt_open_vote and decline_open_vote can be proposed without related_proposal, or decline_open_vote can carry executable ops (opening a SigningSession when passed even though the resolution declines the vote).
    • adopt_open_vote can be proposed against an already-closed non-passed (outcome != "passed") or already-declined proposal, or against an ops-carrying proposal with mismatched ops (not portal.same_ops), causing the resolution to pass dead or execute divergent operations.
  2. Direction inversion and interim refer/defer mismatches in portal.decide:
    • portal.decide allows recording decision="adopt" while citing a decline_open_vote resolution, or decision="decline" while citing an adopt_open_vote (or ops-carrying) resolution.
    • Interim refer / defer citations do not enforce adopt_open_vote outcome and same_ops agreement.
  3. TOCTOU withdrawal race and dead SigningSession citation (portal._decision_resolution):
    • _decision_resolution reads Resolution without FOR UPDATE (populate_existing=True), allowing a concurrent withdraw transaction to race portal.decide / refer.
    • When a passed resolution opened a SigningSession that was subsequently cancelled or failed (so its on-chain ops will never execute), portal._decision_resolution still accepts that resolution as live authority to mark the proposal adopted.

Impact

A proposal decision recorded on public governance surfaces can invert the direction of the cited resolution, cite a resolution whose SigningSession was cancelled/failed and will never execute on-chain, race a concurrent resolution withdrawal, or open an executable SigningSession from a decline_open_vote resolution.

Thread

Khanhtnq2026-11-13 06:10 UTCgithub

Proposed fix opened in https://github.com/xeprotocol/dao/pull/5.

Joseph Denneteam2026-11-15 10:27 UTCgithub

Thanks. This is the same finding as https://bounty.xe.network/XE-11651, which was filed first; the programme pays the first verifiable submission, so this one closes as a duplicate. If you believe it is a different bug, file a new report that links https://bounty.xe.network/XE-13381 and says what differs; it is read like any other.