Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1000 CNY

100.0%

CVE-2026-40566— FreeScout vulnerable to SSRF via IMAP/SMTP Connection Test Endpoints

CVSS 4.1 · Medium EPSS 0.03% · P9
Get alerts for future matching vulnerabilitiesLog in to subscribe

I. Basic Information for CVE-2026-40566

Vulnerability Information

Have questions about the vulnerability? See if Shenlong's analysis helps!
View Shenlong Deep Dive ↗

Although we use advanced large model technology, its output may still contain inaccurate or outdated information.Shenlong tries to ensure data accuracy, but please verify and judge based on the actual situation.

Vulnerability Title
FreeScout vulnerable to SSRF via IMAP/SMTP Connection Test Endpoints
Source: NVD (National Vulnerability Database)
Vulnerability Description
FreeScout is a free self-hosted help desk and shared mailbox. Versions prior to 1.8.213 have a Server-Side Request Forgery (SSRF) vulnerability in the IMAP/SMTP connection test functionality of FreeScout's `MailboxesController`. Three AJAX actions `fetch_test` (line 731), `send_test` (line 682), and `imap_folders` (line 773) in `app/Http/Controllers/MailboxesController.php` pass admin-configured `in_server`/`in_port` and `out_server`/`out_port` values directly to `fsockopen()` via `Helper::checkPort()` and to IMAP/SMTP client connections with zero SSRF protection. There is no IP validation, no hostname restriction, no blocklist of internal ranges, and no call to the project's own `sanitizeRemoteUrl()` or `checkUrlIpAndHost()` functions. The validation block in `connectionIncomingSave()` is entirely commented out. An authenticated admin can configure a mailbox's IMAP or SMTP server to point at any internal host and port, then trigger a connection test. The server opens raw TCP connections (via `fsockopen()`) and protocol-level connections (via IMAP client or SMTP transport) to the attacker-specified target. The response differentiates open from closed ports, enabling internal network port scanning. When the IMAP client connects to a non-IMAP service, the target's service banner or error response is captured in the IMAP debug log and returned in the AJAX response's `log` field, making this a semi-blind SSRF that enables service fingerprinting. In cloud environments, the metadata endpoint at `169[.]254[.]169[.]254` can be probed and partial response data may be leaked through protocol error messages. This is distinct from the `sanitizeRemoteUrl()` redirect bypass (freescout-3) -- different code path, different root cause, different protocol layer. Version 1.8.213 patches the vulnerability.
Source: NVD (National Vulnerability Database)
CVSS Information
CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:C/C:L/I:N/A:N
Source: NVD (National Vulnerability Database)
Vulnerability Type
服务端请求伪造(SSRF)
Source: NVD (National Vulnerability Database)
Vulnerability Title
FreeScout 安全漏洞
Source: CNNVD (China National Vulnerability Database)
Vulnerability Description
FreeScout是FreeScout公司的一个使用 PHP(Laravel 框架)构建的超轻量级且功能强大的免费开源帮助台和共享收件箱。 FreeScout 1.8.213之前版本存在安全漏洞,该漏洞源于MailboxesController中的IMAP/SMTP连接测试功能将配置值直接传递给fsockopen,可能导致经过身份验证的管理员配置服务器指向任意内部主机和端口,进行内部网络端口扫描和服务指纹识别。
Source: CNNVD (China National Vulnerability Database)
CVSS Information
N/A
Source: CNNVD (China National Vulnerability Database)
Vulnerability Type
N/A
Source: CNNVD (China National Vulnerability Database)

Affected Products

VendorProductAffected VersionsCPESubscribe
freescout-help-deskfreescout < 1.8.213 -

II. Public POCs for CVE-2026-40566

#POC DescriptionSource LinkShenlong Link
AI-Generated POCPremium

No public POC found.

Login to generate AI POC

III. Intelligence Information for CVE-2026-40566

登录查看更多情报信息。

Same Patch Batch · freescout-help-desk · 2026-04-21 · 20 CVEs total

CVE-2026-411939.1 CRITICALFreeScout has Zip Slip path traversal in module installation that allows arbitrary file wr
CVE-2026-405699.0 CRITICALFreeScout's Mass Assignment in Mailbox Connection Settings Enables Silent Email Exfiltrati
CVE-2026-405688.5 HIGHFreeScout Vulnerable to XSS via Mailbox Signature Due to Incomplete HTML Sanitization
CVE-2026-404978.1 HIGHFreeScout Vulnerable to CSS Injection via Stored Style Tag in Mailbox Signature (CSRF Toke
CVE-2026-405897.6 HIGHFreeScout has Customer Edit Cross-Mailbox Email Takeover
CVE-2026-411907.1 HIGHFreeScout has assigned-only visibility bypass via save_draft that allows hidden conversati
CVE-2026-411897.1 HIGHFreeScout has assigned-only visibility bypass that allows editing hidden customer-authored
CVE-2026-411917.1 HIGHFreeScout's signature only mailbox permission allows unauthorized mailbox chat setting cha
CVE-2026-405917.1 HIGHFreeScout: Improper Authorization in Phone Conversation Creation Enables Cross-Mailbox Hid
CVE-2026-411927.1 HIGHFreeScout's client-controlled attachment IDs allow deletion of existing conversation attac
CVE-2026-405656.1 MEDIUMFreeScout has Stored XSS / CSS Injection via linkify() — Unescaped URL in Anchor href
CVE-2026-405925.9 MEDIUMFreeScout's cross-user undo reply allows mailbox peers to recall another agent's outbound
CVE-2026-405675.8 MEDIUMFreeScout has HTML Injection in Outgoing Emails via Unsanitized Customer Name in Signature
CVE-2026-411945.4 MEDIUMFreeScout's Mailbox OAuth disconnect uses a state-changing GET and is CSRFable
CVE-2026-411834.3 MEDIUMFreeScout allows non-folder conversation queries to disclose assigned-only hidden conversa
CVE-2026-405904.3 MEDIUMFreeScout's Customer AJAX Create Modifies Hidden Existing Customer
CVE-2026-40570FreeScout's Missing Authorization in load_customer_info Allows Any Authenticated User to A
CVE-2026-40498FreeScout has Authentication Bypass and Information Disclosure in SystemController via /sy
CVE-2026-40496FreeScout has Predictable Attachment Token that Allows Unauthenticated Private File Downlo

IV. Related Vulnerabilities

V. Comments for CVE-2026-40566

No comments yet


Leave a comment