DevMeth
C32

Input handling

Webhook Signature Check — Are Your Endpoints Verifying Providers?

DevMeth checks the 48 known AI-code failure patternsnot a penetration test or a security guarantee.

What the issue is

A webhook endpoint that processes payloads without verifying the provider's signature lets anyone POST a fake event — such as a forged payment-success — and your server acts on it as if it were real.

Why AI tools generate it

AI code generators wire the happy path (receive event, update database) and skip the signature check, because the check needs a raw-body read and an endpoint secret the demo never had.

How DevMeth detects it

A code scan finds webhook routes that write to your database or trigger actions, and flags any route with no signature-verification call on its payload path — or anywhere in the repo it could import.

C32
What a finding looks like
Critical

Your webhook endpoints act on payloads anyone can POST

WHAT WE FOUND

C32masked sample

Sample — illustrative and masked exactly as a real report shows it. Run a free scan to see your own results.

The fix, in three steps

Verify the provider's signature over the raw body inside each webhook handler, gate every action behind that check, and reject with a non-2xx on failure. Three steps.

Run a free scan and each finding carries a paste-ready fix prompt you can act on.

Try a free scan

FAQ

Why does the raw body matter?

Signatures are computed over the exact bytes the provider sent. If your framework parses and re-serializes the body first, verification silently fails or, worse, is skipped — read the raw text, verify, then parse.

Where does the endpoint secret come from?

The provider's dashboard, when you register the webhook URL. Keep it in an environment variable and never commit it.

What's the worst a fake webhook can do?

Whatever your handler does: mark unpaid orders as paid, grant plan access, reset accounts, or trigger emails — all without ever touching the provider.

DevMeth checks the 48 known AI-code failure patternsnot a penetration test or a security guarantee. A clear result means each known pattern was checked and found clear or not applicable for your app; it is not a guarantee of security.