The SentinelOne Annual Threat Report - A Defenders Guide from the FrontlinesThe SentinelOne Annual Threat ReportGet the Report
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2026-40565

CVE-2026-40565: Freescout Help Desk XSS Vulnerability

CVE-2026-40565 is an XSS vulnerability in Freescout Help Desk caused by improper handling of URLs in email bodies. Attackers can inject malicious HTML attributes. This article covers technical details, affected versions, and patches.

Published: April 23, 2026

CVE-2026-40565 Overview

CVE-2026-40565 is a Cross-Site Scripting (XSS) vulnerability affecting FreeScout, a free self-hosted help desk and shared mailbox application. The vulnerability exists in the linkify() function within app/Misc/Helper.php, which converts plain-text URLs in email bodies into HTML anchor tags without properly escaping double-quote characters (") in the URL. This improper input sanitization allows attackers to break out of the href attribute and inject arbitrary HTML attributes, potentially leading to XSS attacks.

Critical Impact

Attackers can inject malicious HTML attributes into email content viewed by FreeScout users, potentially stealing session cookies, redirecting users to phishing sites, or performing actions on behalf of authenticated users.

Affected Products

  • FreeScout versions prior to 1.8.213
  • FreeScout self-hosted help desk installations
  • FreeScout shared mailbox deployments

Discovery Timeline

  • 2026-04-21 - CVE CVE-2026-40565 published to NVD
  • 2026-04-22 - Last updated in NVD database

Technical Details for CVE-2026-40565

Vulnerability Analysis

This vulnerability stems from an input validation flaw in how FreeScout processes URLs embedded within email bodies. The application uses HTMLPurifier via the getCleanBody() function to sanitize HTML content, which correctly preserves literal double-quote characters (") in text nodes as part of valid text. However, when the subsequent linkify() function processes these sanitized text nodes to convert URLs into clickable anchor tags, it fails to escape the double-quote characters before embedding them within the href="..." attribute.

This sequence creates a dangerous condition where an attacker can craft a URL containing double-quote characters that, after processing, breaks out of the href attribute boundary. Once outside the attribute context, the attacker can inject arbitrary HTML attributes such as onclick, onmouseover, or other event handlers that execute JavaScript code when triggered by user interaction.

The vulnerability is exploitable over the network and requires user interaction (viewing the malicious email content), but does not require authentication, making it accessible to external attackers who can send emails to the help desk system.

Root Cause

The root cause is improper output encoding in the linkify() function located in app/Misc/Helper.php. While HTMLPurifier correctly handles HTML sanitization for the email body content, the subsequent URL-to-anchor conversion fails to account for special characters that have meaning in HTML attribute contexts. Specifically, the function does not call htmlspecialchars() or equivalent encoding on URL strings before embedding them in the href attribute, allowing double-quote characters to terminate the attribute prematurely.

Attack Vector

The attack is network-based and requires an attacker to send a crafted email to a FreeScout mailbox. The malicious email contains a URL with embedded double-quote characters followed by arbitrary HTML attributes. When a help desk agent or user views the email through FreeScout's web interface, the linkify() function processes the URL and generates malformed HTML that includes the attacker's injected attributes.

The exploitation flow involves the attacker crafting a URL with special characters that escape the href attribute context. When the linkify() function processes text like http://example.com"onclick="alert(1), it wraps this in an anchor tag, but the unescaped double quote terminates the href attribute early, allowing the onclick handler to be injected as a separate attribute. When the victim clicks the malicious link or hovers over it, the injected JavaScript executes in their browser session.

Detection Methods for CVE-2026-40565

Indicators of Compromise

  • Unusual email content containing URLs with embedded double-quote characters or HTML attribute patterns
  • Web server logs showing requests originating from XSS payload execution
  • Session anomalies indicating potential session hijacking after email viewing
  • User reports of unexpected browser behavior when viewing help desk tickets

Detection Strategies

  • Monitor incoming emails for URLs containing suspicious patterns like "onclick=, "onmouseover=, or similar HTML event handlers
  • Implement Content Security Policy (CSP) headers to detect and block inline script execution attempts
  • Review FreeScout application logs for errors related to malformed HTML rendering
  • Deploy web application firewall (WAF) rules to detect XSS injection patterns in email content

Monitoring Recommendations

  • Enable browser console logging to capture JavaScript errors indicative of XSS attempts
  • Configure SentinelOne to monitor for suspicious script execution originating from email viewing contexts
  • Set up alerts for unusual outbound connections from user browsers that may indicate data exfiltration
  • Monitor for changes to user session tokens or authentication states after email interaction

How to Mitigate CVE-2026-40565

Immediate Actions Required

  • Upgrade FreeScout to version 1.8.213 or later immediately
  • Review recent help desk tickets for suspicious email content containing unusual URL patterns
  • Implement Content Security Policy headers to mitigate potential XSS impact
  • Educate help desk staff about the risks of interacting with suspicious email content

Patch Information

FreeScout has addressed this vulnerability in version 1.8.213. The fix ensures that double-quote characters and other special characters are properly escaped before being embedded in HTML attributes within the linkify() function. The patch can be verified through the GitHub Commit Reference. For detailed information about the vulnerability and fix, refer to the GitHub Security Advisory GHSA-49pm-xwqj-vwjp.

Workarounds

  • Disable automatic URL linking in email bodies if the feature is configurable in your FreeScout installation
  • Implement strict Content Security Policy headers to prevent execution of injected scripts
  • Use a web application firewall to filter incoming emails containing suspicious URL patterns
  • Consider viewing email content in plain-text mode until the patch can be applied
bash
# Update FreeScout to the patched version
cd /path/to/freescout
git fetch --all
git checkout 1.8.213
php artisan freescout:after-app-update

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypeXSS

  • Vendor/TechFreescout

  • SeverityMEDIUM

  • CVSS Score6.1

  • EPSS Probability0.03%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityLow
  • AvailabilityNone
  • CWE References
  • CWE-79
  • Technical References
  • GitHub Release 1.8.213
  • Vendor Resources
  • GitHub Commit Reference

  • GitHub Security Advisory GHSA-49pm-xwqj-vwjp
  • Related CVEs
  • CVE-2026-40568: FreeScout Stored XSS Vulnerability

  • CVE-2026-40567: FreeScout Email XSS Vulnerability

  • CVE-2026-40496: FreeScout Auth Bypass Vulnerability

  • CVE-2026-40497: FreeScout Privilege Escalation Flaw
Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the World’s Most Advanced Cybersecurity Platform

See how our intelligent, autonomous cybersecurity platform can protect your organization now and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English