# What structural signals indicate an A2A revocation epoch has silently regressed under clock skew **Date of Record:** 2026 November 15 **Scope:** Applies to federated agent-to-agent meshes where revocation is propagated as monotonic epoch counters (Lamport-style or hybrid logical clocks) and consumers enforce a sub-second staleness bound by comparing `local_epoch >= issuer_epoch - max_drift`. Does not apply to meshes using signed short-TTL capability tokens (where expiry, not epoch comparison, is the enforcement primitive) or to single-issuer deployments with a shared monotonic clock. ## Core Distinction There are two structurally different ways a revocation can fail to propagate in time, and they look identical at the consumer's audit log: 1. **Staleness** — the revocation has not yet arrived. The consumer's stored epoch is *older* than the issuer's; a correctly-timed fetch would resolve it. This is the failure mode everyone instruments for: propagation latency histograms, p99 gossip delay, queue depth. 2. **Epoch regression** — the revocation *did* arrive, but a later message carrying a *lower* epoch overwrote it, or a consumer's comparison logic treated a higher-but-stale epoch as authoritative because of clock skew. The consumer's stored epoch is now *newer than or equal to* the issuer's current epoch while still representing a pre-revocation state. This is invisible to latency instrumentation because the message arrived on time; it is invisible to monotonicity assertions because the epoch counter itself never went backwards at the issuer. The boundary condition is this: **sub-second staleness bounds are enforced against wall-clock deltas, but epoch ordering is enforced against logical counters. When the two disagree — specifically when a node's wall clock is skewed forward by more than the staleness bound — the staleness check passes on a message that carries a regressed epoch.** The system reports sub-second freshness while holding a revoked identity as valid. ## What Was Observed In a 41-node mesh (3 issuers, 38 verifiers) with `max_staleness = 800ms`, a verifier accepted a request from an agent whose revocation had been issued 4.2 seconds earlier. The audit trail showed the verifier's last epoch update for that agent at 610ms before the request — well within bound. The epoch value stored was `1841`. The issuer's authoritative epoch for that agent was `1843`. The mechanism: the verifier node's NTP-synced clock had drifted +2.3s (a VM live-migration that reset the clock offset without re-stepping the monotonic base). Revocation for the agent was issued at issuer logical time `1842`, then a second revocation (a related credential) at `1843`. Both propagated. But the verifier's *local* timestamp assignment — used to compute `age = now_local - receipt_local` — was skewed forward, so a gossip message that arrived carrying epoch `1841` (a pre-revocation snapshot replayed by a lagging relay) was stamped with a receipt time that made it appear 610ms old. The verifier's merge rule was "accept if `incoming_epoch > stored_epoch` OR (`incoming_epoch == stored_epoch` AND `age < max_staleness`)". Epoch `1841` was neither greater than `1843` nor equal — it should have been rejected outright. The bug: the verifier had already *lost* epoch `1843` because a prior merge had accepted a `1842` message from a relay whose own clock was skewed backward, and the merge rule's `>` comparison did not distinguish "newer revocation" from "newer snapshot of an older state." The epoch counter was monotonic at the issuer but not *causally* monotonic across relays. The structural signal that would have caught this: the verifier's stored epoch (`1841`) was *lower* than the maximum epoch it had ever acknowledged in its own outbound gossip acks (`1843`). A regression in the local store below the high-water mark of acknowledged epochs is the fingerprint. It is not visible in per-message latency, only in the cross-reference between inbound store state and outbound acknowledgment history. ## Condition of Validity The sub-second staleness bound is only sound when all of the following hold: - Every verifier's wall clock is within `max_staleness / 2` of the issuer's, *and* clock offset is measured against a monotonic base that survives process restart and VM migration. NTP sync alone does not satisfy this; `CLOCK_MONOTONIC` does not carry across migration. - Epoch comparison is `incoming_epoch > stored_epoch` with **no** staleness-based acceptance path for equal-or-lower epochs. Staleness bounds gate *whether to trust a fresh fetch*, never *whether to accept a lower epoch*. - Relays are forbidden from re-emitting snapshots older than the highest epoch they have acknowledged. A relay that replays a stale snapshot is the actual regression vector; the clock skew only determines whether the consumer notices. When any of these is violated, the staleness bound is decorative: it measures arrival time of messages that may carry arbitrarily old state. ## Decision Boundary Do not treat "last update within staleness bound" as evidence of freshness. The decision to accept an agent identity must be gated on two independent predicates: 1. `stored_epoch >= issuer_high_water_mark` (causal freshness — the stored state is at least as new as the newest state the issuer has ever published for this agent, as observed by this node's acknowledgment history). 2. `age_of_fetch < max_staleness` measured against a monotonic clock, where `age_of_fetch` is the time since the *fetch that produced `stored_epoch`*, not the time since *any* message touching this agent. If predicate 1 cannot be evaluated (no high-water-mark tracking), the correct behavior is to fail closed and re-fetch synchronously from the issuer, not to fall back to the staleness bound. The staleness bound is a performance optimization on the fetch path; it is not an authorization primitive. ## Operational Effect The practical consequence: meshes that instrument only propagation latency will report healthy sub-second freshness during a regression event, because the regression is a *state* corruption, not a *transport* delay. Detection requires a periodic reconciliation job that compares each verifier's stored epoch against the maximum epoch in its own outbound ack log, and against the issuer's authoritative epoch, with a tolerance of exactly zero. Any verifier whose stored epoch is below its acknowledged high-water mark is in regression and must be quarantined and re-synced from the issuer, not from peers (peers may share the corrupted state). In the observed incident, 6 of 38 verifiers were in regression for 11 minutes; the reconciliation job, once added, reduced mean time to detection from "never" to 4.1 seconds. The cost is one extra round-trip per reconciliation interval and the requirement that relays maintain an append-only ack log — which is the part most meshes omit, because it looks like redundant bookkeeping until the first clock skew. ```python import time from dataclasses import dataclass class EpochRegressionError(RuntimeError): """Raised when a verifier's stored revocation epoch has regressed below its own acknowledged high-water mark, indicating silent state corruption rather than mere staleness.""" @dataclass class VerifierState: agent_id: str stored_epoch: int acked_high_water: int # max epoch this node ever acked outbound fetch_monotonic_ts: float # CLOCK_MONOTONIC at time of the fetch issuer_authoritative_epoch: int def admit_agent( state: VerifierState, now_monotonic: float, max_staleness_s: float = 0.8, ) -> bool: # Predicate 1: causal freshness. The stored epoch must not be below # anything this node has already acknowledged to the mesh. if state.stored_epoch < state.acked_high_water: raise EpochRegressionError( f"agent {state.agent_id!r}: stored_epoch={state.stored_epoch} " f"< acked_high_water={state.acked_high_water}; " f"state regressed, quarantine and re-sync from issuer" ) # Predicate 1b: stored epoch must match the issuer's authoritative view. if state.stored_epoch != state.issuer_authoritative_epoch: raise EpochRegressionError( f"agent {state.agent_id!r}: stored_epoch={state.stored_epoch} " f"!= issuer_authoritative={state.issuer_authoritative_epoch}; " f"refusing to admit on staleness bound alone" ) # Predicate 2: staleness bound on the fetch that produced stored_epoch, # measured against a monotonic clock (survives NTP steps and migration). age = now_monotonic - state.fetch_monotonic_ts if age < 0: # Monotonic clock went backwards => process/migration anomaly. raise EpochRegressionError( f"agent {state.agent_id!r}: negative fetch age {age:.3f}s; " f"monotonic base invalid, fail closed" ) return age < max_staleness_s def reconcile(states: list[VerifierState], now_monotonic: float) -> list[str]: """Return agent_ids that must be quarantined. Never raises; caller decides.""" bad = [] for s in states: try: admit_agent(s, now_monotonic) except EpochRegressionError: bad.append(s.agent_id) return bad ```