fix(health-steal): bound healing and retain recovery proof #13

Merged
dmg merged 1 commits from us-049-steal-health-from-defeated-enemies into main 2026-10-08 15:36:58 +00:00
Owner

US-049 / FS-SEC-14 — Health Steal native and persisted-state safeguards

  • Preserve the inherited remediation, rebased onto current main d4ae188501828e01b19b2f89adf8404787d3670d.
  • Use current native health rather than stale saved health; round the durable target down to a representable native float within the accepted budget and maximum. Honor native cancellation/revalidation and consume each defeat/publication callback once.
  • Force a separate operation-bound Health Steal proof before provisional health replacement, including no-op targets. Confirm native publication or reconcile the still-owned health component under exact snapshots, preserving unrelated progress and newer health.
  • Unresolved/failed/ambiguous saves, changed sessions/native state, rejected callbacks or uncertain cleanup retain proof and block later loading/entry, including restart. No automatic proof deletion or healing replay. Document the deliberately conservative availability trade-off and separately reviewed recovery requirement.
  • Add native and persistence regression coverage; drive the existing combat-reward retry in the connected Fireball test without changing its exact reward, health, attribution, duplicate or cooldown assertions.

Verification

  • Meaningful retained RED: float rounding exceeded an accepted0.3 budget; repeated no-op-save callback replayed healing after later damage; failed reconciliation enabled fresh entry at5 instead of actual2; approved-policy RED demonstrated the missing load barrier.
  • Scoped barrier/recovery verification:42 native +13 API cases, zero failures/errors/skips.
  • Broader affected run:463 API +55 tools passed;110 native cases had one Fireball fixture failure. That failure is retained; all13 Fireball cases passed after driving its existing reward retry and awaiting the exact XP acknowledgment.
  • Full ./gradlew clean check jar: 2,409 tests (1,891 native /463 API /55 tools), zero failures/errors/skips, 17m14s. All656 source and110 runtime-JAR hashes unchanged.
  • All649 remaining native SEVERE first-cause signatures match verified main; the only delta from668 is19 missing-PDC Health Steal fixture errors removed after supplying its real native PDC. No added signatures or suppression; no blanket listener/security clearance.
  • Frozen candidate tree: 4d570b34b3bf1933fdb3ded9d5fd35fd5cec5264;656 source and110 pinned runtime-JAR hashes in /tmp/us049-resumption/inputs.json.
  • Evidence: /tmp/us049-resumption/; canonical story: somc-okf/user-stories/purpur-fantasy-stick/us-049-steal-health-from-defeated-enemies.md.

No balance/configuration, runner, deadline, CI/tooling, GitOps or deployment changes. Second Wind proof semantics remain separate and unchanged. This PR does not claim final-plugin security clearance or deployment readiness. Required current-head checks and tested-tree merge verification still apply.

Tested head: 403dd4b78a4fb15ea5e2efb5d70c4386a6e788df.

## US-049 / FS-SEC-14 — Health Steal native and persisted-state safeguards - Preserve the inherited remediation, rebased onto current main `d4ae188501828e01b19b2f89adf8404787d3670d`. - Use current native health rather than stale saved health; round the durable target down to a representable native float within the accepted budget and maximum. Honor native cancellation/revalidation and consume each defeat/publication callback once. - Force a separate operation-bound Health Steal proof before provisional health replacement, including no-op targets. Confirm native publication or reconcile the still-owned health component under exact snapshots, preserving unrelated progress and newer health. - Unresolved/failed/ambiguous saves, changed sessions/native state, rejected callbacks or uncertain cleanup retain proof and block later loading/entry, including restart. No automatic proof deletion or healing replay. Document the deliberately conservative availability trade-off and separately reviewed recovery requirement. - Add native and persistence regression coverage; drive the existing combat-reward retry in the connected Fireball test without changing its exact reward, health, attribution, duplicate or cooldown assertions. ## Verification - Meaningful retained RED: float rounding exceeded an accepted0.3 budget; repeated no-op-save callback replayed healing after later damage; failed reconciliation enabled fresh entry at5 instead of actual2; approved-policy RED demonstrated the missing load barrier. - Scoped barrier/recovery verification:42 native +13 API cases, zero failures/errors/skips. - Broader affected run:463 API +55 tools passed;110 native cases had one Fireball fixture failure. That failure is retained; all13 Fireball cases passed after driving its existing reward retry and awaiting the exact XP acknowledgment. - Full `./gradlew clean check jar`: **2,409 tests** (1,891 native /463 API /55 tools), zero failures/errors/skips, **17m14s**. All656 source and110 runtime-JAR hashes unchanged. - All649 remaining native SEVERE first-cause signatures match verified main; the only delta from668 is19 missing-PDC Health Steal fixture errors removed after supplying its real native PDC. No added signatures or suppression; no blanket listener/security clearance. - Frozen candidate tree: `4d570b34b3bf1933fdb3ded9d5fd35fd5cec5264`;656 source and110 pinned runtime-JAR hashes in `/tmp/us049-resumption/inputs.json`. - Evidence: `/tmp/us049-resumption/`; canonical story: `somc-okf/user-stories/purpur-fantasy-stick/us-049-steal-health-from-defeated-enemies.md`. No balance/configuration, runner, deadline, CI/tooling, GitOps or deployment changes. Second Wind proof semantics remain separate and unchanged. This PR does not claim final-plugin security clearance or deployment readiness. Required current-head checks and tested-tree merge verification still apply. Tested head: `403dd4b78a4fb15ea5e2efb5d70c4386a6e788df`.
dmg added 1 commit 2026-10-08 15:33:46 +00:00
fix(health-steal): bound healing and retain recovery proof
CI / build (push) Successful in 46s
CI / build (pull_request) Successful in 49s
403dd4b78a
dmg merged commit 3a184d5298 into main 2026-10-08 15:36:58 +00:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: dmg/purpur-fantasy-stick#13