IOSOR Learn
Enforcing Webhook Replay Windows for OTP Verification
Define strict timestamp replay windows on verify webhooks to block stale delivery receipts from inflating conversion metrics, then compare providers on clock-skew tolerance via Decision Brief.
Lead Telecom & Routing Architect · Lausanne, CH
Operators must enforce a narrow replay window — typically 30–60 seconds — on every verify webhook so that delayed or replayed DLR receipts cannot be counted as fresh conversions. The gate rejects any payload whose timestamp falls outside the allowed skew from the verification request time, using monotonic server clocks and signed timestamps to prevent manipulation.
Timestamp Window Configuration
Set the replay window per corridor based on observed webhook latency percentiles (p99 + safety margin). Store the original verification request timestamp in a short-lived cache keyed by message-id; on webhook receipt, compare the provider's timestamp field against the cached value and reject if delta exceeds the configured window. Log every rejection with reason code for audit.
Clock Skew Tolerance & Monotonic Sources
Require providers to include a signed, monotonic timestamp (e.g., RFC 3339 with nanosecond precision) in each webhook. Validate against a trusted time source (NTP pool or GPS-disciplined clock) with a maximum allowed skew of ±2 seconds. Reject any webhook where the provider's clock drifts beyond this bound, as it indicates either misconfiguration or a replay attempt.
Signature Validation & Replay Detection
Every webhook must carry an HMAC-SHA256 signature over the canonical payload including the timestamp. Verify the signature before timestamp checks to ensure payload integrity. Maintain a sliding-window bloom filter of recently seen message-id + timestamp pairs to detect exact replays within the window; increment a replay counter per sender for anomaly alerting.
Conversion Metric Integrity
Only count a verification as converted when the webhook passes timestamp, signature, and replay checks. Exclude rejected webhooks from conversion funnels entirely — do not bucket them as 'failed' or 'delayed'. Export clean metrics to BI with a verified_webhook=true flag so downstream dashboards reflect true user conversion rates.
Partner Route Comparison & Evaluation
Compare verified partner routes for timestamp validation, clock-skew handling, and replay window enforcement. Checklist: 1) Confirm provider includes signed monotonic timestamp in webhook. 2) Measure p99 webhook latency per corridor to set window. 3) Test replay rejection with synthetic delayed payloads. 4) Verify bloom-filter replay detection at scale. 5) Ensure conversion metrics exclude rejected webhooks.
Start with IOSOR
Use the Decision Brief to compare providers on timestamp validation, clock-skew tolerance, and replay window enforcement for your corridors. Configure the gate, deploy the bloom filter, and lock conversion metrics to verified webhooks only. Enforcing Webhook Replay Windows for OTP Verification. OTP Webhook Replay Signature Validation Gate. Verify Webhook Replay Attack Surface Reduction.
IOSOR takeaway
Set the replay window per corridor based on observed webhook latency percentiles (p99 + safety margin). Compare verified partner routes for timestamp validation, clock-skew handling, and replay window enforcement. Every webhook must carry an HMAC-SHA256 signature over the canonical payload including the timestamp. Verify the signature before timestamp checks to ensure payload integrity.
Was this guide helpful?
Related guides
- OTP Velocity Cap Drift Detection: Verify Route Failover Before Abuse Escalates
Detect silent per-route OTP velocity cap drift, audit DLR and webhook evidence, and compare failover-ready partner routes before abuse spikes hit your funnel.
- Verifying OTP Delivery Receipts Against Forged Success Signals
How ops leads test whether DLR and webhook success signals are auditable before trusting OTP conversion and fraud dashboards, and pick routes with receipt integrity.
- OTP Velocity Fencing: Auditing Threshold Drift Before It Leaks Fraud
How to audit per-account, per-number, and per-IP OTP velocity fences for silent threshold drift after rule changes, traffic mix shifts, or partner filter updates.












