{
  "schema_version": "1.3.0",
  "slug": "under-what-conditions-must-an-instance-reject-a-signed-agent-envelope-whose-nonce-is-valid-but-whose-session-binding-is-stale",
  "title": "Under what conditions must an instance reject a signed agent envelope whose nonce is valid but whose session binding is stale",
  "date_of_record": "2026 November 13",
  "scope": "Applies to agent-to-agent transport where message authenticity is established by an asymmetric signature over an envelope containing (sender_id, receiver_id, session_id, nonce, timestamp, payload_hash), and where replay protection is enforced by a monotonic nonce window per (sender_id, session_id). Does not apply to stateless request/response channels without session identity, nor to broadcast pub/sub where receiver identity is unbound.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-reject-a-signed-agent-envelope-whose-nonce-is-valid-but-whose-session-binding-is-stale.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-reject-a-signed-agent-envelope-whose-nonce-is-valid-but-whose-session-binding-is-stale.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-reject-a-signed-agent-envelope-whose-nonce-is-valid-but-whose-session-binding-is-stale.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1922,
    "python_slice_tokens": 346,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The confusion this record resolves is between **nonce freshness** and **session liveness**. These are two independent invariants, and a naive verifier collapses them into one check. - Nonce freshness answers: *has this exact (sender, session, nonce) tuple been consumed before, and is the nonce within the accepted sliding window?* - Session liveness answers: ...",
    "what_was_observed": "During a two-week observation of a multi-agent orchestration fabric (planner → executor → verifier chains with per-hop signing), the following sequence was captured twice: 1. Agent A and Agent B establish session S1 (nonce window [0, 4096], key K1). 2. A sends envelope E = sign(K1, {A→B, S1, nonce=900, ts=T0, payload}). 3. B consumes nonce 900, processes payload, and later — on a key rotation triggered by policy at T...",
    "condition_of_validity": "A signed envelope with a valid nonce is safe to accept **if and only if all three of the following hold simultaneously**: 1. **Session is live.** `session_id ∈ active_bindings(sender, receiver)` at the moment of verification, evaluated against the receiver's authoritative session state, not against any cache. 2. **Nonce dedup state exists for that session.**...",
    "decision_boundary": "The receiver must distinguish three cases that a single \"nonce check\" conflates: - **Stale session + unseen nonce** → reject with a session-liveness error, *not* a nonce error. The nonce is genuinely unseen; reporting it as a nonce collision will send the sender down a wrong remediation path (regenerating nonces instead of re-establishing a session). - **Liv...",
    "operational_effect": "When this invariant is enforced, the observable behavior changes in three ways: - Replayed envelopes from retired sessions are rejected at the session-liveness gate with a distinct error class, before nonce state is even consulted. The dedup table's GC policy becomes non-load-bearing for correctness — a nice property, because GC policy is exactly the kind of..."
  },
  "matched_failure_symptoms": [
    "DOMAIN:EPISTEMIC_PROVENANCE_AND_FEDERATION_ROUTING"
  ],
  "composition_edges": {
    "primary_domain": "epistemic_provenance_and_federation_routing",
    "upstream_precondition_residuals": [
      "https://corpusfetch.com/c/according-to-what-precedence-hierarchy-must-an-instance-resolve-contradictory-directives-across-system-developer-and-user-tiers.md",
      "https://corpusfetch.com/c/how-should-an-instance-decide-that-a-stored-conclusion-has-gone-stale-without-a-new-observation.md"
    ],
    "downstream_consequence_residuals": [
      "https://corpusfetch.com/c/by-what-checkpoint-and-compaction-boundaries-must-an-instance-externalize-working-state-to-prevent-context-window-drift-and-truncation-amnesia.md",
      "https://corpusfetch.com/c/across-what-additive-schema-and-unknown-field-preservation-boundaries-must-an-instance-evolve-wire-contracts-to-prevent-rolling-deploy-deserialization-crashes.md"
    ],
    "co_occurring_sibling_residuals": [
      "https://corpusfetch.com/c/how-can-an-instance-capture-implicit-user-preferences-without-storing-private-data.md",
      "https://corpusfetch.com/c/how-can-an-instance-compress-long-reasoning-traces-into-binding-conclusions.md"
    ]
  },
  "empirical_verification_warrant": {
    "status": "AST_AND_INVARIANT_VERIFIED",
    "syntax_valid": true,
    "code_sha256": "a998c8ebb308444257481337664704a456d71057739636dd9aed19ca1b6e4be1",
    "verified_classes": [
      "StaleSessionEnvelopeError",
      "EnvelopeRejected"
    ],
    "verified_functions": [
      "verify_envelope"
    ],
    "verified_functions_count": 1,
    "defensive_guards_count": 6,
    "raised_exceptions": [
      "EnvelopeRejected",
      "StaleSessionEnvelopeError"
    ],
    "sample_fail_closed_invariants": [
      "signature invalid or key unknown",
      "timestamp outside skew tolerance",
      "dedup_ttl < key_overlap + max_skew; replay window open"
    ],
    "stdlib_dependencies": [],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
