{"id":"CVE-2025-52478","aliases":["EUVD-2025-25193","GHSA-hfmv-hhh3-43f2"],"status":"published","title":"Stored XSS in n8n Form Trigger allows Account Takeover via injected iframe and video/source","description":"n8n is a workflow automation platform. From 1.77.0 to before 1.98.2, a stored Cross-Site Scripting (XSS) vulnerability was identified in n8n, specifically in the Form Trigger node's HTML form element. An authenticated attacker can inject malicious HTML via an \u003ciframe\u003e with a srcdoc payload that includes arbitrary JavaScript execution. The attacker can also inject malicious Javascript by using \u003cvideo\u003e coupled \u003csource\u003e using an onerror event. While using iframe or a combination of video and source tag, this vulnerability allows for Account Takeover (ATO) by exfiltrating n8n-browserId and session cookies from authenticated users who visit a maliciously crafted form. Using these tokens and cookies, an attacker can impersonate the victim and change account details such as email addresses, enabling full control over the account—especially if 2FA is not enabled. Users should upgrade to version \u003e= 1.98.2.","severity":{"version":"3.1","score":8.7,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N","level":"high","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-10","score":0.00448,"percentile":0.39266,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-79"],"published":"2025-08-19T15:33:35Z","modified":"2026-10-28T02:30:49Z","fixes":[{"ecosystem":"npm","package":"n8n","fixed_in":["1.98.2"],"sources":["ghsa","osv"]}],"affected":[{"source":"ghsa","ecosystem":"npm","package":"n8n","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"1.77.0"},{"fixed":"1.98.2"}]}]},{"source":"osv","ecosystem":"npm","package":"n8n","ranges":[{"type":"SEMVER","events":[{"introduced":"1.77.0"},{"fixed":"1.98.2"}]}]}],"products":[{"vendor":"n8n","product":"n8n"},{"vendor":"n8n-io","product":"n8n"}],"references":[{"url":"https://github.com/n8n-io/n8n/security/advisories/GHSA-hfmv-hhh3-43f2","tags":["x_refsource_CONFIRM","Patch","Vendor Advisory","advisory","web"]},{"url":"https://github.com/n8n-io/n8n/pull/16329","tags":["x_refsource_MISC","Patch","fix","web"]},{"url":"https://github.com/n8n-io/n8n/commit/7940384a85041a1890b1203d69c092c887312500","tags":["x_refsource_MISC","Patch","fix","web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2025-52478","tags":["advisory"]},{"url":"https://github.com/advisories/GHSA-hfmv-hhh3-43f2"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/52xxx/CVE-2025-52478.json","tags":["advisory"]},{"url":"https://github.com/n8n-io/n8n","tags":["package"]}],"sources":{"cve":[{"id":"CVE-2025-52478","title":"Stored XSS in n8n Form Trigger allows Account Takeover via injected iframe and video/source","description":"n8n is a workflow automation platform. From 1.77.0 to before 1.98.2, a stored Cross-Site Scripting (XSS) vulnerability was identified in n8n, specifically in the Form Trigger node's HTML form element. An authenticated attacker can inject malicious HTML via an \u003ciframe\u003e with a srcdoc payload that includes arbitrary JavaScript execution. The attacker can also inject malicious Javascript by using \u003cvideo\u003e coupled \u003csource\u003e using an onerror event. While using iframe or a combination of video and source tag, this vulnerability allows for Account Takeover (ATO) by exfiltrating n8n-browserId and session cookies from authenticated users who visit a maliciously crafted form. Using these tokens and cookies, an attacker can impersonate the victim and change account details such as email addresses, enabling full control over the account—especially if 2FA is not enabled. Users should upgrade to version \u003e= 1.98.2.","status":"published","published":"2025-08-19T16:32:34.949Z","modified":"2025-08-19T19:18:13.3Z","cvss":[{"version":"3.1","score":8.7,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N","level":"high","assessor":"cna"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T14:32:31.631102Z"}],"euvd":[{"id":"EUVD-2025-25193","description":"n8n is a workflow automation platform. From 1.77.0 to before 1.98.2, a stored Cross-Site Scripting (XSS) vulnerability was identified in n8n, specifically in the Form Trigger node's HTML form element. An authenticated attacker can inject malicious HTML via an \u003ciframe\u003e with a srcdoc payload that includes arbitrary JavaScript execution. The attacker can also inject malicious Javascript by using \u003cvideo\u003e coupled \u003csource\u003e using an onerror event. While using iframe or a combination of video and source tag, this vulnerability allows for Account Takeover (ATO) by exfiltrating n8n-browserId and session cookies from authenticated users who visit a maliciously crafted form. Using these tokens and cookies, an attacker can impersonate the victim and change account details such as email addresses, enabling full control over the account—especially if 2FA is not enabled. Users should upgrade to version \u003e= 1.98.2.","status":"published","published":"2025-08-19T16:32:34Z","modified":"2025-08-19T19:18:13Z","cvss":[{"version":"3.1","score":8.7,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N","level":"high"}],"updated_at":"2026-11-02T20:31:55.90596Z"}],"ghsa":[{"id":"GHSA-hfmv-hhh3-43f2","title":"Stored XSS in n8n Form Trigger allows Account Takeover via injected iframe and video/source","description":"### Impact\n\nA stored **Cross-Site Scripting (XSS)** vulnerability was identified in [n8n](https://github.com/n8n-io/n8n), specifically in the **Form Trigger** node's **HTML form element**. An authenticated attacker can inject malicious HTML via an `\u003ciframe\u003e` with a `srcdoc` payload that includes arbitrary JavaScript execution. The attacker can also inject malicious Javascript by using `\u003cvideo\u003e` coupled `\u003csource\u003e` using an `onerror` event.\n\nWhile using `iframe` or a combination of `video` and `source` tag, this vulnerability allows for Account Takeover (ATO) by exfiltrating `n8n-browserId` and session cookies from authenticated users who visit a maliciously crafted form. Using these tokens and cookies, an attacker can impersonate the victim and change account details such as email addresses, enabling full control over the account—especially if 2FA is not enabled.\n\n### Patches\nThe issue was addressed in [PR #16329](https://github.com/n8n-io/n8n/pull/16329). Users should upgrade to version \u003e=1.98.2.\n\n### Workarounds\nApart from updating to the fixed version, n8n instance administrators can:\n- Configure a reverse proxy to **serve webhook requests from a different domain** [[docs](https://docs.n8n.io/hosting/configuration/configuration-examples/webhook-url/)].\n- Disable or restrict use of the **Form Trigger node**, particularly the **HTML** element type.\n- Use a Content Security Policy (CSP) to block execution of inline scripts and disallow use of `srcdoc`.\n\n### References\n- [OWASP XSS Prevention Cheat Sheet](https://cheatsheetseries.owasp.org/cheatsheets/XSS_Prevention_Cheat_Sheet.html)\n- [MDN: iframe `srcdoc` attribute](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe#attr-srcdoc)\n- [HTML: `onerror` attribute](https://html.spec.whatwg.org/multipage/webappapis.html#handler-onerror)","status":"published","published":"2025-08-19T15:33:35Z","modified":"2025-08-19T20:58:34Z","cvss":[{"version":"3.1","score":8.7,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N","level":"high"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T14:38:53.767052Z"}],"nvd":[{"id":"CVE-2025-52478","description":"n8n is a workflow automation platform. From 1.77.0 to before 1.98.2, a stored Cross-Site Scripting (XSS) vulnerability was identified in n8n, specifically in the Form Trigger node's HTML form element. An authenticated attacker can inject malicious HTML via an \u003ciframe\u003e with a srcdoc payload that includes arbitrary JavaScript execution. The attacker can also inject malicious Javascript by using \u003cvideo\u003e coupled \u003csource\u003e using an onerror event. While using iframe or a combination of video and source tag, this vulnerability allows for Account Takeover (ATO) by exfiltrating n8n-browserId and session cookies from authenticated users who visit a maliciously crafted form. Using these tokens and cookies, an attacker can impersonate the victim and change account details such as email addresses, enabling full control over the account—especially if 2FA is not enabled. Users should upgrade to version \u003e= 1.98.2.","status":"published","published":"2025-08-19T17:15:40.617Z","modified":"2026-06-17T09:36:34.183Z","cvss":[{"version":"3.1","score":8.7,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N","level":"high","assessor":"secondary"},{"version":"3.1","score":5.4,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N","level":"medium","assessor":"primary"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T14:11:24.730342Z"}],"osv":[{"id":"CVE-2025-52478","title":"Stored XSS in n8n Form Trigger allows Account Takeover via injected iframe and video/source","description":"n8n is a workflow automation platform. From 1.77.0 to before 1.98.2, a stored Cross-Site Scripting (XSS) vulnerability was identified in n8n, specifically in the Form Trigger node's HTML form element. An authenticated attacker can inject malicious HTML via an \u003ciframe\u003e with a srcdoc payload that includes arbitrary JavaScript execution. The attacker can also inject malicious Javascript by using \u003cvideo\u003e coupled \u003csource\u003e using an onerror event. While using iframe or a combination of video and source tag, this vulnerability allows for Account Takeover (ATO) by exfiltrating n8n-browserId and session cookies from authenticated users who visit a maliciously crafted form. Using these tokens and cookies, an attacker can impersonate the victim and change account details such as email addresses, enabling full control over the account—especially if 2FA is not enabled. Users should upgrade to version \u003e= 1.98.2.","status":"published","published":"2025-08-19T16:32:34.949Z","modified":"2026-10-28T02:30:49.063609308Z","cvss":[{"version":"3.1","score":8.7,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N","level":"high"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T15:44:50.45326Z"},{"id":"GHSA-hfmv-hhh3-43f2","title":"Stored XSS in n8n Form Trigger allows Account Takeover via injected iframe and video/source","description":"### Impact\n\nA stored **Cross-Site Scripting (XSS)** vulnerability was identified in [n8n](https://github.com/n8n-io/n8n), specifically in the **Form Trigger** node's **HTML form element**. An authenticated attacker can inject malicious HTML via an `\u003ciframe\u003e` with a `srcdoc` payload that includes arbitrary JavaScript execution. The attacker can also inject malicious Javascript by using `\u003cvideo\u003e` coupled `\u003csource\u003e` using an `onerror` event.\n\nWhile using `iframe` or a combination of `video` and `source` tag, this vulnerability allows for Account Takeover (ATO) by exfiltrating `n8n-browserId` and session cookies from authenticated users who visit a maliciously crafted form. Using these tokens and cookies, an attacker can impersonate the victim and change account details such as email addresses, enabling full control over the account—especially if 2FA is not enabled.\n\n### Patches\nThe issue was addressed in [PR #16329](https://github.com/n8n-io/n8n/pull/16329). Users should upgrade to version \u003e=1.98.2.\n\n### Workarounds\nApart from updating to the fixed version, n8n instance administrators can:\n- Configure a reverse proxy to **serve webhook requests from a different domain** [[docs](https://docs.n8n.io/hosting/configuration/configuration-examples/webhook-url/)].\n- Disable or restrict use of the **Form Trigger node**, particularly the **HTML** element type.\n- Use a Content Security Policy (CSP) to block execution of inline scripts and disallow use of `srcdoc`.\n\n### References\n- [OWASP XSS Prevention Cheat Sheet](https://cheatsheetseries.owasp.org/cheatsheets/XSS_Prevention_Cheat_Sheet.html)\n- [MDN: iframe `srcdoc` attribute](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe#attr-srcdoc)\n- [HTML: `onerror` attribute](https://html.spec.whatwg.org/multipage/webappapis.html#handler-onerror)","status":"published","published":"2025-08-19T15:33:35Z","modified":"2025-08-19T20:58:33Z","cvss":[{"version":"3.1","score":8.7,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N","level":"high"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T15:46:48.920784Z"}]}}
