X-Xquik-Signature header containing an HMAC-SHA256 signature. Always verify this signature before processing events.
How It Works
- Xquik computes
sha256=+ HMAC-SHA256(webhook secret, raw JSON body) - The result is sent in the
X-Xquik-Signatureheader - Your server recomputes the signature and compares using constant-time comparison
Implementation
Security Checklist
Always verify before processing
Always verify before processing
Never process webhook payloads without verifying the signature first. An unverified payload could be a spoofed request.
Use constant-time comparison
Use constant-time comparison
Use
timingSafeEqual (Node.js), hmac.compare_digest (Python), or hmac.Equal (Go). String equality (===) is vulnerable to timing attacks.Use the raw request body
Use the raw request body
Compute the HMAC over the raw request body bytes, not a re-serialized JSON object. Re-serialization can alter whitespace or key ordering.
Respond quickly
Respond quickly
Return
200 within 10 seconds. Process events asynchronously if your handler is slow.