<!-- XE-0604 · ticket.award events publish the held assessed_tier: the public log discloses a severity the ticket API withholds, nine events after ticket.facts redacts it · testnet -->
*Markdown view of <https://bounty.xe.network/XE-0604>. The page is the record; this is the same page for reading.*

XE-0604 · Bounty

# ticket.award events publish the held assessed\_tier: the public log discloses a severity the ticket API withholds, nine events after ticket.facts redacts it

Awarded
Minorclaimed Medium
web
filed 2026-11-05 06:13 UTC
by Ashev Ardiansyah

Verdict
:   Valid

Tier
:   Minor

Claimed
:   Medium

Area
:   Other

Duplicate of
:   —

Tracked
:   —

Award
:   50 XE approved
    · ceiling 650

Updated
:   2026-11-09 21:02 UTC

Told
:   2026-11-08 21:28 UTC

### Patches

- [desk@fb93a8aa28](https://github.com/xeprotocol/desk/commit/fb93a8aa284bd145bcad9c30266d1aa5a721cdcf)

### History

- [57342](https://bounty.xe.network/log/57342) 2026-11-09 21:02 UTC ticket.status disclosed → awarded
- [57341](https://bounty.xe.network/log/57341) 2026-11-09 21:02 UTC ticket.status patched → disclosed
- [57340](https://bounty.xe.network/log/57340) 2026-11-09 21:02 UTC ticket.disclosed

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

### Report

## Component and version

The bounty desk, `bounty.xe.network`, source `github.com/xeprotocol/desk`.

- HEAD at review: `14c35b8ecadb06d4b4eb4fd98e4db62f39a5dcd9` (2026-11-05 04:44:42 UTC)
- The control this report is about was introduced by `f323a99511d8e08b912618978cb595db3d164ffe`
  ("publish the assessment with the fix, not before"), 2026-11-05 04:40:38 UTC.
- Live deployment confirmed as `network.id = testnet-0005`, `version 0.1.0`
  via `GET https://bounty.xe.network/v1`.

Method: static source review plus read-only unauthenticated HTTP GETs against the live
desk. No credentials were used. Nothing was written. No other user's data was touched.

## Summary

`f323a99` introduced a hold on the team's assessment of an open bug. While a bounty
ticket sits in `new`, `triaging`, `needs-info`, `accepted` or `fixing`, `assessed_tier`,
`verdict`, `mainnet_gate`, `effort_eng` and `internal_ref` are withheld from readers
outside the team and its agents.

The hold is enforced on two paths and missed on a third.

`desk/services/tickets.py:754,767` — the ticket serializer gates the field:

```
full = sees_assessment(p)
shown = full or not assessment_held(t)
...
"assessed_tier": t.assessed_tier if shown else None,
```

`desk/log.py:269-274,294-306` — the log serializer strips it out of `ticket.facts`
payloads:

```
HELD_FACT_KEYS = frozenset({"assessed_tier", "verdict", "mainnet_gate", "effort_eng", "internal_ref"})
HELD_PAYLOAD_KEYS = {
    "ticket.facts": frozenset({"reason"}),
    "ticket.status": frozenset({"reason"}),
    "proposal.created": frozenset({"value"}),
}
...
def public_payload(kind, payload):
    drop = TEAM_ONLY_KEYS | HELD_PAYLOAD_KEYS.get(kind, frozenset())
    out = {k: v for k, v in payload.items() if k not in drop}
    if kind == "ticket.facts" and isinstance(out.get("changes"), dict):
        kept = {k: v for k, v in out["changes"].items() if k not in HELD_FACT_KEYS}
        ...
```

`desk/services/tickets.py:727-739` — the third path, `set_award()`, writes the same
value into a `ticket.award` event under the key `tier`, and `ticket.award` has no entry
in `HELD_PAYLOAD_KEYS`:

```
await ctx.events.append(
    db,
    "ticket.award",
    p.actor,
    {
        "ticket": t.id,
        "award_xe": t.award_xe,
        "approved": bool(t.award_approved_at),
        "tier": t.assessed_tier,        # <- line 735: the held field, under a different key name
    },
    ref=t.id,
    public=t.visibility == "public",
)
```

Because the denylist is keyed on `(kind, payload key)` and this event uses the key
`tier` rather than `assessed_tier`, `public_payload()` passes it through untouched. The
event is written with `public=True` for every public-visibility ticket and is served to
anonymous readers by `GET /v1/log`, `GET /v1/log?ref=<ticket>`, `GET /v1/log/{index}`,
`GET /v1/events` and `GET /v1/events/stream`.

The result is that the desk redacts the assessment in one event and publishes it in
another, on the same ticket, in the same log stream, a few indices apart.

## What I did

1. Read `f323a99` and enumerated the three serialization paths for `assessed_tier`
   (`to_dict`, `public_payload`/`ticket.facts`, `set_award`/`ticket.award`).
2. Paged the anonymous public log: `GET /v1/log?offset=0&limit=1000` and
   `?offset=1000&limit=1000` — 1,710 events, no credentials.
3. Collected every `ticket.award` event (12 of them).
4. For each, requested the public ticket endpoint `GET /v1/tickets/{id}` and compared
   the `tier` in the log payload against `assessed_tier` in the ticket response, plus
   the ticket's `status` against `ASSESSMENT_HELD`.
5. Saved the whole cross-check as `poc_evidence.json`; the runnable script is
   `poc_desk_public_log_leak.py`.

## What happened

Two live tickets currently disclose a held assessment. Verbatim from the run at
2026-11-05T05:51:10Z:

```
ticket        XE-0483  (event index 5383, public=True)
api status    accepted   -> assessment_held = True
GET /v1/tickets/XE-0483  ->  assessed_tier = None     (WITHHELD)
GET /v1/log?ref=XE-0483  ->  ticket.award.tier = 'minor'   (DISCLOSED)

ticket        XE-0462  (event index 5438, public=True)
api status    accepted   -> assessment_held = True
GET /v1/tickets/XE-0462  ->  assessed_tier = None     (WITHHELD)
GET /v1/log?ref=XE-0462  ->  ticket.award.tier = 'medium'  (DISCLOSED)
```

XE-0462 shows the contradiction inside a single log stream. The full anonymous
`GET /v1/log?ref=XE-0462` response, newest first:

```
idx=5439  proposal.adopted  {"field": "award_xe", "reason": "", "ticket": "XE-0462", "proposal": 404}
idx=5438  ticket.award      {"tier": "medium", "ticket": "XE-0462", "approved": false, "award_xe": 800000000}
idx=5437  proposal.adopted  {"field": "status", ...}
idx=5436  ticket.status     {"to": "accepted", "from": "triaging", "via": "proposal:403", ...}
idx=5434  proposal.adopted  {"field": "effort_eng", ...}
idx=5433  ticket.facts      {"changes": {}, "held": ["effort_eng"], "via": "proposal:402"}
idx=5432  proposal.adopted  {"field": "mainnet_gate", ...}
idx=5431  ticket.facts      {"changes": {}, "held": ["mainnet_gate"], "via": "proposal:401"}
idx=5430  proposal.adopted  {"field": "assessed_tier", ...}
idx=5429  ticket.facts      {"changes": {}, "held": ["assessed_tier"], "via": "proposal:400"}
idx=5428  proposal.adopted  {"field": "verdict", ...}
idx=5427  ticket.facts      {"changes": {}, "held": ["verdict"], "via": "proposal:399"}
```

At index 5429 the desk correctly reduces the `assessed_tier` change to
`{"changes": {}, "held": ["assessed_tier"]}` — it names the field and withholds the
value, exactly as `f323a99` intends. Nine indices later, at 5438, `ticket.award`
publishes `"tier": "medium"` for the same ticket.

## What I expected

`GET /v1/log?ref=XE-0462` served to an anonymous reader should not contain the
`assessed_tier` of a ticket in a held status. Either `ticket.award` should join
`HELD_PAYLOAD_KEYS` with `{"tier"}`, or — better, since a denylist has to be remembered
for every new event kind — `public_payload()` should filter held fact *values* by
vocabulary rather than by key name, or `set_award()` should emit the tier only when
`not assessment_held(t)`.

## Reproduce

Read-only, unauthenticated, standard library only:

```
python3 poc_desk_public_log_leak.py --out poc_evidence.json
```

Or by hand:

```
curl -s 'https://bounty.xe.network/v1/tickets/XE-0462' | jq '{status,claimed_tier,assessed_tier,verdict}'
curl -s 'https://bounty.xe.network/v1/log?ref=XE-0462&limit=100' \
  | jq '.events[] | select(.kind=="ticket.award") | {index,public,payload}'
```

Expected output is in `poc_output.txt`; the machine-readable cross-check of all 12
`ticket.award` events is in `poc_evidence.json`.

## Impact

The hold exists because, in the words of the comment above `ASSESSMENT_HELD` in
`desk/services/tickets.py:224-227`:

```
# While a bug is confirmed and unfixed, the team's assessment of it (tier, verdict, gate, effort, which
# internal ticket carries it) is a ranked list of what works against XE and when it will stop working.
```

`ticket.award` leaks one field of that list — the confirmed severity — for any public
ticket that has reached the point where an award amount is set, which is precisely the
window in which the bug is accepted, unfixed and awaiting a patch. An unauthenticated
reader learns which confirmed-but-unfixed findings the team rates highest, before the
fix ships and before the public page is meant to say so. The same commit gated
`GET /v1/export/triage.md` behind `sees_assessment()` for exactly this reason; the log
path was not covered.

Scope of the leak is bounded, and I want to be precise about that rather than overstate
it:

- Only `assessed_tier` leaks on this path. `verdict`, `mainnet_gate`, `effort_eng` and
  `internal_ref` remain correctly withheld.
- It only fires on public-visibility tickets. Events on private tickets are written
  `public=False`, and Critical and Severe reports are private by default
  (`desk/services/reporters.py:38`, `PRIVATE_TIERS = ("critical", "severe")`), so the
  sealed reports are not exposed by this path.
- `to_dict` already serves `award_xe` unconditionally (`tickets.py:777`), so the award
  amount itself is public by design and is not part of this claim. Because the ceiling
  table in `config/desk.yaml` maps tiers to amounts, a reader can already infer an
  approximate band from `award_xe` alone; the incremental disclosure is the exact
  confirmed tier rather than an inferred one.

On that basis I claim **Medium** and I think **Minor** is a defensible assessment. The
reason I did not claim Minor is that this defeats a control the team shipped in the same
release, on the same data, and the two paths visibly contradict each other within one
ticket's log — so the fix belongs with `f323a99` rather than being treated as cosmetic.

## Suggested fix

Smallest change, in `desk/log.py`:

```
HELD_PAYLOAD_KEYS = {
    "ticket.facts": frozenset({"reason"}),
    "ticket.status": frozenset({"reason"}),
    "proposal.created": frozenset({"value"}),
    "ticket.award": frozenset({"tier"}),
}
```

That mirrors the existing pattern but leaves the denylist keyed on event kind, so any
future event that carries a held value under a new name repeats the bug. Two more
durable options:

1. Filter by value vocabulary instead of key name — hold any payload value that
   equals a `TIERS`/`VERDICTS`/`GATES`/`EFFORTS` member when the referenced ticket is
   in `ASSESSMENT_HELD`. This needs the ticket lookup `public_payload()` does not
   currently have, so it would move to the call sites.
2. Stop emitting the held value at the source: in `set_award()`, include `tier` only
   when `not assessment_held(t)`. The award event keeps its meaning (`award_xe`,
   `approved`) and the tier is published later by the normal `patched`-onwards path.

Option 2 is the smallest diff and cannot regress when a new event kind appears.

## Prior-art check

I checked this against every open and closed ticket on the desk and every issue on
`xeprotocol/xe` before filing. The related desk findings are distinct in root cause,
data subject and reader:

- XE-0322 — an agent token holding `read:private` reads *reporters'* payout addresses
  and sign-in IPs from events written `public=False`. Root cause is the coarse
  `read:private` gate on the log read routes. Here the events are written `public=True`
  and the reader is anonymous with no credentials at all.
- XE-0344 — `reply.sent` payloads carry the private reply *body*. Different event kind,
  different data. That report notes "every sibling path follows the invariant" and
  checks `note.added` and `ticket.created`; it does not examine `ticket.award`.
- XE-0345 — the `public` flag, `ref` and signature presence sit outside the hash
  envelope. A tamper-evidence issue, not a disclosure one.
- XE-0212 — `GET /v1/tickets/{id}/log` over-serves to the *owning reporter* of a
  private ticket. Different principal and different route gate.
- XE-0519 — the award ceiling fails open when `assessed_tier` is unset. Concerns the
  award amount computation, not its disclosure.
- XE-0310 — the anonymous leaderboard leaks identity and award totals of still-private
  tickets. Different endpoint (`leaderboard()`), different data.

Nothing on the desk or on `xeprotocol/xe` mentions `ticket.award`, `HELD_PAYLOAD_KEYS`,
or the `f323a99` assessment hold.

## Bounds

Read-only. I did not create, modify, withdraw or reply to any ticket; did not sign in;
did not use or attempt to use any credential, cookie, token or invitation; did not write
to the desk database; did not test the SSE stream beyond reading its source; and did not
run any load against the desk or the testnet. The attached script issues only
unauthenticated `GET` requests to `bounty.xe.network` and writes one local file.

The two live examples are tickets whose bodies are already public, and the disclosed
values are the desk's own severity labels for them, quoted here because they are the
evidence. No sealed report content was accessed or is reproduced.

### Thread

**Joseph Denne**team2026-11-08 20:17 UTCdesk

Thanks for the report. We have confirmed the gap you describe in the desk's public log and it is being handled together with a related fix. We will update you here: https://bounty.xe.network/XE-0604

**Joseph Denne**team2026-11-08 21:28 UTCdesk

Thanks for the report. The fix is on the desk now; this ticket moves to patched, and the assessment and any award follow the fix.
