Join our Newsletter — 33% off our NHI Course

Webhook Replay Window

A webhook replay window is the short time period in which an incoming event signature is considered valid. Limiting that window, along with nonces and signature verification, reduces the chance that captured events can be resent later to trigger unauthorized actions or duplicate processing.

Expanded Definition

A webhook replay window defines how long a receiver will accept a signed event as fresh. It is part of the broader trust check around webhook delivery, where the receiver verifies the signature, checks timing, and rejects events that fall outside the accepted interval. This is not the same as transport security or general API authentication: the replay window is a message-level control that limits how long a captured payload remains useful.

In practice, the concept usually sits alongside a timestamp, nonce, event ID, or one-time token. The exact tolerance is often an implementation choice rather than a universal standard, so guidance varies by platform and provider. A shorter window reduces reuse risk but can create false rejections when clocks drift or queueing delays are normal. A longer window is easier operationally, but it enlarges the period in which a stolen or intercepted webhook can still be replayed. The common boundary mistake is to assume signature verification alone prevents reuse; it does not if the signed message remains acceptable for too long.

Examples and Use Cases

  • An e-commerce platform accepts payment-status webhooks only if the timestamp is recent, preventing an old “payment approved” event from being resent after settlement state has changed.
  • A SaaS integration stores webhook event IDs and rejects duplicates inside the replay window, reducing double-processing when retries, race conditions, or packet capture are involved.
  • A CI/CD system validates that deployment webhooks are both signed and time-bound before triggering release automation, so a copied request cannot be used later to start the same job again.
  • An identity workflow receives account-provisioning notifications from a directory service and treats stale events as invalid, which helps avoid re-creating or re-enabling accounts from a captured message.

Because webhook delivery is often retried, teams sometimes widen the acceptance window to avoid breaking legitimate traffic. That trade-off improves reliability, but it also raises the amount of time an attacker can reuse a valid signed request if they obtain one.

Security Implications

When the replay window is too permissive, a captured webhook can be resent to trigger the same business action more than once. The result may be duplicate orders, repeated status transitions, unintended provisioning, or repeated automation in downstream systems. In environments that rely on webhooks for privileged workflow changes, the issue can become an authorization problem as well as an integrity problem, because the receiver may treat a stale message as newly trusted.

Failure often shows up as inconsistent event histories, duplicate records, or actions that appear to come from the same sender but at the wrong time. If the receiver does not bind freshness checks to a nonce or event identifier, an intercepted payload can remain useful until the signature expires. Practitioners should also watch for clock skew and retry logic that mask replay-related defects during testing but expose them in production.

Domain and Governance Relevance

Webhook replay windows matter most where event-driven integrations carry security-critical state changes. In identity and access workflows, a stale webhook can distort account lifecycle actions, approval chains, or entitlement updates, especially when downstream systems act automatically on receipt. That makes freshness control part of trust governance, not just a technical detail of message validation.

The NHI angle is real when webhooks are used to move machine-to-machine signals, service notifications, or automation triggers that act without human review. Those flows often rely on shared secrets, signing keys, or integration tokens, so replay protection helps preserve the integrity of non-human identity activity. For teams building or consuming such events, the practical question is not only whether the sender is authenticated, but whether the specific message is still within the organisation’s accepted trust period.

Standards & Framework Alignment

This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.

OWASP Non-Human Identity Top 10 and MITRE ATT&CK address the attack and risk surface, while CIS Controls v8 and NIST CSF 2.0 set the governance and control requirements practitioners need to meet.

Framework Control / Reference Relevance
OWASP Non-Human Identity Top 10 NHI-01 — Secrets and Credential Management Webhook replay protection depends on protected signing secrets and token handling.
NHI-03 — Inventory and Ownership Replay risk grows when webhook identities, keys, and event owners are not clearly governed.
Recommendation — Rotate webhook signing secrets and reject stale or duplicated signed events. Assign ownership for webhook identities and track the event sources that can act automatically.
CIS Controls v8 6 — Access Control Management Replayable webhooks can re-trigger privileged actions if access paths lack freshness checks.
Recommendation — Enforce time-bound validation for event-driven access paths and revoke stale trust.
NIST CSF 2.0 PR.AC-3 — Remote Access is Managed Webhook receivers must manage authenticated inbound machine-to-machine access carefully.
Recommendation — Apply authenticated remote-access controls that verify event freshness before execution.
MITRE ATT&CK T1550 — Use Alternate Authentication Material A replayed webhook reuses valid authentication material to gain unauthorized effect.
Recommendation — Detect reuse of signed webhook material and block repeated use of the same message.