NewApp Monitoring is liveSign up free
AgentbeamBeta
AI agent vulnerability · n8n

CVE-2025-68949: n8n: Webhook Node IP Whitelist Bypass via Partial String Matching

mediumCVSS 3.1 5.3GHSA-w96v-gf22-crwp

The n8n Webhook node checks its IP whitelist by substring match instead of exact comparison, so a caller whose IP merely contains a whitelisted entry passes. This affects n8n 1.36.0 up to but not including 2.2.0, for both IPv4 and IPv6. Upgrade to n8n 2.2.0.

Published Jan 13, 2026 · Analysis Nov 1, 2026

What an attacker can do

The Webhook node's IP whitelist option is meant to restrict which source addresses can trigger a workflow. In affected versions, an incoming request was accepted if its source address contained the configured entry as a substring. If an editor whitelisted 10.1.1.1, a caller from 10.1.1.15 or 10.1.1.100 would also match. Short or prefix-style entries widen the hole.

The attacker needs network access to the webhook URL and a source address that shares the right text with a trusted one. That is feasible in cloud and ISP address blocks. They then trigger the workflow without being on the list. What they get depends on the workflow: it may start automations, write to databases, call internal APIs or send messages. The CVSS vector is network, no privileges, no user interaction, with low confidentiality impact. The flaw only matters for webhooks that rely on the IP whitelist as their sole control.

Who is affected

The npm package n8n from 1.36.0 up to 2.2.0 (exclusive). Only workflows with a Webhook node that sets an IP whitelist are exposed. Check the version:

npm ls n8n

For Docker, read the image tag or run n8n --version inside the container. Then open your workflows and look for Webhook nodes with an IP(s) Whitelist option set.

n8n

Ecosystem
npm
Affected
>= 1.36.0, < 2.2.0
Fixed in
2.2.0
Check
npm ls n8n

How to fix it

Upgrade to n8n 2.2.0 or later:

npm install -g n8n@latest

Version 2.2.0 compares IP addresses strictly rather than by partial match. If you cannot upgrade, the advisory recommends not relying on IP whitelisting alone. Add a shared secret, HMAC signature or API key check. Avoid short or prefix-based whitelist entries. Enforce IP filtering at the network layer, for example in a reverse proxy or firewall.

How to tell if you were hit

Review execution logs for webhook-triggered runs whose source address is not exactly one of the whitelisted values. Compare the client IPs in your reverse proxy or load balancer logs with the whitelist entries on each Webhook node. Hits from addresses that start with or contain a whitelisted entry, but are not equal to it, point to this bypass.

Original advisory

From the GitHub Advisory Database (CC BY 4.0).

Impact

The Webhook node’s IP whitelist validation performed partial string matching instead of exact IP comparison. As a result, an incoming request could be accepted if the source IP address merely contained the configured whitelist entry as a substring.

This issue affected instances where workflow editors relied on IP-based access controls to restrict webhook access. Both IPv4 and IPv6 addresses were impacted. An attacker with a non-whitelisted IP could bypass restrictions if their IP shared a partial prefix with a trusted address, undermining the intended security boundary.

Patches

This issue has been patched in version 2.2.0.

Users are advised to upgrade to v2.2.0 or later, where IP whitelist validation uses strict IP comparison logic rather than partial string matching.

Workarounds

Users unable to upgrade immediately should avoid relying solely on IP whitelisting for webhook security. Recommended mitigations include:

  • Adding authentication mechanisms such as shared secrets, HMAC signatures, or API keys.
  • Avoiding short or prefix-based whitelist entries.
  • Enforcing IP filtering at the network layer (for example, via reverse proxies or firewalls).

Credited to berkdedekarginoglu.

Questions

Does this give code execution on the n8n host?

No. The flaw bypasses the webhook IP whitelist. The advisory does not describe code execution. The impact is that an unlisted caller can trigger the workflow behind the webhook.

Is IPv6 affected too?

Yes. The advisory says both IPv4 and IPv6 addresses were affected by the partial matching.

What should I use instead of an IP whitelist?

The advisory suggests authentication such as shared secrets, HMAC signatures or API keys, plus filtering at a reverse proxy or firewall.

References

How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. The analysis is written by an AI model from the sources listed above and checked by automated rules before it is published. Check versions against the vendor's advisory before you act. Methodology

More n8n vulnerabilities

All n8n entries