/

CVE-2026-94567

Severity:

CRITICAL RISK

(9.3)

SVG Script Injection (CWE-79) in NukeViet CMS Upload

CVE-2026-94567

Received

Vulnerability type

Category:

SVG-Based Stored Cross-Site Scripting

CWE:

CWE-79, CWE-434, CWE-436

Impact:

Stored Cross-Site Scripting (Same-Origin Script Execution)

Severity:

CRITICAL RISK

(9.3)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

NukeViet's SVG upload handling can leave a script hidden inside a DTD entity that its sanitizer does not inspect, while browsers may expand that entity when rendering the stored file. If an attacker can submit an SVG through an enabled upload flow, the file may enable same-origin script execution when served.

Affected context

The issue is in NukeViet's SVG upload and sanitization path. The risk arises when an uploaded SVG contains script content in an internal DTD entity: the upload checks do not expand that entity, the sanitizer inspects element nodes only, and the original bytes can be stored without image verification. Browsers may expand the entity when the file is served as image/svg+xml.

Exploit preconditions

  • Attack surface: SVG uploads through guest comment attachments or the module file manager.
  • Required access: Guest-level access may be sufficient when a module's comments are open to the All or Guest group and comment attachments are enabled. Otherwise, access to the relevant module administration or file manager may be required.
  • Trigger point: The uploaded SVG is later served and rendered by a browser as image/svg+xml.
  • Why exploitation is possible: Entity expansion and sanitizer inspection differ; script content hidden in an entity can escape element-only checks and remain in the stored file.

Why this happens

This combines insufficient output sanitization (CWE-79), improper handling of uploaded files (CWE-434), and inconsistent interpretation of input (CWE-436). The upload path checks an SVG without expanding its DTD entity, while the sanitizer examines only element nodes; the browser may later interpret the preserved entity differently and expose the script content. The SVG path also returns before image verification, leaving the original bytes unchanged.

Potential impact

  • A browser may execute attacker-controlled script in the site's origin.
  • An administrator who views the stored SVG could have their session or page actions exposed to same-origin script.
  • The issue could enable unauthorized actions available to the affected user's account.
  • If guest comment attachments are enabled for a public module, an unauthenticated attacker may be able to submit the file.

General mitigation guidance

Defensive patterns include parsing and sanitizing SVG using a consistent, well-defined representation, and rejecting DTDs or entity references when they are not required. Apply strict format and content allowlists, ensure all upload paths pass through equivalent validation, and avoid preserving untrusted source bytes after sanitization. Where SVG does not need to be rendered inline, consider serving it as a download or from an isolated origin; restrict upload and administrative privileges to the minimum needed.

How teams detect issues like this

  • Use static analysis and code review to find SVG parsers that permit DTDs or entity references, sanitizers that inspect only selected node types, and upload branches that bypass verification.
  • Check that validation, sanitization, and serving behavior use consistent parsing and interpretation rules.
  • Review policies for SVG uploads, comment attachments, and content served as image/svg+xml; test that disabled attachment permissions are enforced.
  • Automated security review tools may help identify risky parser and upload patterns.

Sources

SourceLink
github.comgithub.com/nukeviet/nukeviet/blob/4.5.13/CHANGELOG.txt
github.comgithub.com/nukeviet/nukeviet/commit/912823e2581afc23dc39dabdb7d94c718efc78f6
github.comgithub.com/nukeviet/nukeviet/commit/b4abcddd3a3a628e251d88571f3968822fab4406
github.comgithub.com/nukeviet/nukeviet/releases/tag/4.6.02
github.comgithub.com/nukeviet/nukeviet/security/advisories/GHSA-cp55-wmv6-wxpp
nukeviet.vnnukeviet.vn/vi/news/Tin-tuc/thong-bao-phat-hanh-nukeviet-4-6-02-858.html

Frequently asked

questions

Potentially. A remote attacker may be able to submit an SVG if a module allows guest comment attachments and attachment uploads are enabled; otherwise, relevant file-manager access may be needed.

Not in every configuration. Guest submission is possible only when the affected module's comment access and attachment settings permit it.

Reject unnecessary DTD and entity constructs, sanitize SVG using a parser that handles the content consistently, and ensure every upload path validates the final stored representation.

Minimize trust in uploaded files, enforce consistent validation across upload routes, isolate active content from the application origin where practical, and limit upload privileges.

Find out what's already
exploitable in your codebase.