Skip to content

[DEN-3467] Add replay-bounded command envelopes and receipts - #2

Draft
ORESoftware wants to merge 3 commits into
mainfrom
agent/den-3467-command-envelope
Draft

[DEN-3467] Add replay-bounded command envelopes and receipts#2
ORESoftware wants to merge 3 commits into
mainfrom
agent/den-3467-command-envelope

Conversation

@ORESoftware

@ORESoftware ORESoftware commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add protocol-v1 CommandEnvelope with device/boot identity, monotonic sequence, issue/expiry timestamps, and canonical SHA-256 payload digest
  • cap command TTL at five minutes and expose duplicate/out-of-order validation
  • validate nested configure/show/ping commands
  • add CommandReceipt with accepted/applied/duplicate/expired/unsupported/rejected/failed outcomes
  • bind receipts to the exact command session, sequence, and digest
  • add four protocol tests while retaining the legacy DeviceEvent::Ack

Compatibility boundary

This is an additive first slice of DEN-3467. It intentionally does not remove or reinterpret the legacy ACK, add protocol negotiation to Hello, or implement device-side persistent replay windows. Those changes require coordinated controller/server/SDK vectors under DEN-3470.

Validation

GitHub Actions passes:

  • cargo fmt --all -- --check
  • cargo clippy --all-targets --all-features -- -D warnings
  • cargo test --all-targets --all-features

The first run surfaced only rustfmt layout differences; the exact CI diff was applied and the full rerun passed.

Linear: https://linear.app/denman/issue/DEN-3467/leddy-version-expire-and-replay-protect-device-commands-and

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant