<!-- XE-11651 · [DAO] `portal.decide` + `resolutions.decide` tidak pernah cek `matter`: keputusan adopt/decline bisa tertukar dan `decline_open_vote` yang lolos bisa membuka SigningSession · testnet -->
*Markdown view of <https://bounty.xe.network/XE-11651>. The page is the record; this is the same page for reading.*

XE-11651 · Bounty

# \[DAO\] \`portal.decide\` \+ \`resolutions.decide\` tidak pernah cek \`matter\`: keputusan adopt/decline bisa tertukar dan \`decline\_open\_vote\` yang lolos bisa membuka SigningSession

Triaging
claimed Medium
web
filed 2026-11-13 07:01 UTC
by cunels

Verdict
:   published when the fix ships

Tier
:   published when the fix ships

Claimed
:   Medium

Area
:   DAO harness

Duplicate of
:   —

Tracked
:   —

Updated
:   2026-11-15 11:08 UTC

Told
:   2026-11-15 10:27 UTC

### Patches

None linked.

### History

- [260081](https://bounty.xe.network/log/260081) 2026-11-15 11:08 UTC proposal.adopted
- [260080](https://bounty.xe.network/log/260080) 2026-11-15 11:08 UTC ticket.award
- [258845](https://bounty.xe.network/log/258845) 2026-11-15 10:27 UTC proposal.adopted
- [258844](https://bounty.xe.network/log/258844) 2026-11-15 10:27 UTC reply.sent
- [258331](https://bounty.xe.network/log/258331) 2026-11-15 10:27 UTC proposal.adopted
- [258330](https://bounty.xe.network/log/258330) 2026-11-15 10:27 UTC ticket.status new → triaging
- [257028](https://bounty.xe.network/log/257028) 2026-11-15 10:27 UTC proposal.adopted
- [257027](https://bounty.xe.network/log/257027) 2026-11-15 10:27 UTC ticket.facts
- [257026](https://bounty.xe.network/log/257026) 2026-11-15 10:27 UTC proposal.adopted
- [257025](https://bounty.xe.network/log/257025) 2026-11-15 10:27 UTC ticket.facts area
- [257024](https://bounty.xe.network/log/257024) 2026-11-15 10:27 UTC proposal.adopted
- [257023](https://bounty.xe.network/log/257023) 2026-11-15 10:27 UTC ticket.facts

[Full history](https://bounty.xe.network/log?ref=XE-11651) · [JSON](https://bounty.xe.network/v1/tickets/XE-11651) · [markdown](https://bounty.xe.network/XE-11651.md)

### Report

Judul: \[DAO\] `portal.decide` \+ `resolutions.decide` tidak pernah cek `matter`: keputusan adopt/decline bisa tertukar dan `decline_open_vote` yang lolos bisa membuka SigningSession

Letak Bug:
`dao/dao/services/resolutions.py:122-165` — `decide` memanggil `open_session(ctx, db, r)` begitu `r.ops` terisi dan suara `for` mencapai ambang, tanpa pernah memeriksa `r.matter`. Resolusi dengan `matter=decline_open_vote` yang membawa `ops` dan lolos voting akan membuka SigningSession yang bisa dieksekusi. `dao/dao/services/portal.py:370-384` — `_decision_resolution` hanya memeriksa keberadaan resolusi, `related_proposal == pr.hash`, dan status (passed untuk adopt, open-or-passed untuk referral) — tidak pernah memeriksa `matter`. `portal.decide` (baris 413\+) untuk adopt-with-ops hanya memeriksa `same_ops(resolution.ops, pr.ops)`, bukan arah matter. `propose` (66–91) hanya memvalidasi keberadaan `related_proposal` (XE-1945) dan kecocokan `ops` dengan jenis sesi dari `matter` (XE-0349) — bukan apakah kombinasi `matter`\+`ops` itu koheren dengan proposal terkait.

Seberapa Buruk Bug nya:
Resolusi `decline_open_vote` yang membawa `ops` dan lolos voting akan membuka SigningSession yang bisa dieksekusi — kebalikan dari yang diputuskan para anggota (mereka memvoting sebuah penolakan, sistem mengeksekusi operasi). Sebaliknya, keputusan `adopt` bisa mengutip resolusi `decline_open_vote` (dan `decline`/`referral` bisa mengutip resolusi `adopt`), sehingga catatan tata kelola yang dipublikasikan menyatakan kebalikan dari hasil voting — integritas rekaman governance rusak. Bonus: pembacaan Resolution di `_decision_resolution` memakai `select(...)` biasa tanpa `with_for_update()` (berbeda dengan `portal.get(lock=True)`, XE-0672/XE-0960), membuka balapan decide/withdraw, dan tidak ada cek apakah sesi terkait masih hidup.

### Thread

**Joseph Denne**team2026-11-15 10:27 UTCdesk

Thanks for the report. We have read it against the current tree. The code does what was intended here, and whether the intended behaviour should change is with the team for a decision.
