CVE-2026-40565 FreeScout has Stored XSS / CSS Injection via linkify() — Unescaped URL in Anchor href

Medium 6.1 Published Updated

Attackers can inject malicious scripts via unescaped URLs in email bodies, potentially leading to session hijacking or code execution in FreeScout.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
A user has to click or open something
Fix
None listed

What is CVE-2026-40565?

CVE-2026-40565 is a medium-severity cross-site scripting vulnerability in freescout-help-desk freescout, published on 21 Apr 2026. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.

Official description

FreeScout is a free self-hosted help desk and shared mailbox. Prior to version 1.8.213, FreeScout's linkify() function in app/Misc/Helper.php converts plain-text URLs in email bodies into HTML anchor tags without escaping double-quote characters (") in the URL. HTMLPurifier (called first via getCleanBody()) preserves literal " characters in text nodes. linkify() then wraps URLs including those " chars inside an unescaped href="..." attribute, breaking out of the href and injecting arbitrary HTML attributes. Version 1.8.213 fixes the issue.

Weakness: CWE-79

Which versions are affected by CVE-2026-40565?

It affects 1 product.

Products include Freescout Freescout.

How do I fix CVE-2026-40565?

No fix has been published for CVE-2026-40565 yet. Limit exposure of the affected software until one is available.

Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.

Is CVE-2026-40565 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-40565 exists.

Sources

Also known as GHSA-49pm-xwqj-vwjp.

Is CVE-2026-40565 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free