/

CVE-2026-54065

Severity:

HIGH RISK

(8.7)

Path Traversal (CWE-22) in NukeViet CMS Comment Deletion

CVE-2026-54065

Received

Vulnerability type

Category:

Path Traversal

CWE:

CWE-22

Impact:

Unauthorized File Deletion and Denial of Service

Severity:

HIGH RISK

(8.7)

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 CMS can store a crafted attachment path submitted by an authenticated administrator without checking that it remains within the intended upload directory. When the associated comment is deleted, the stored path may allow deletion of application files, potentially causing an outage.

Affected context

The issue affects NukeViet CMS versions prior to 4.5.09 in the comment administration workflow. The edit handler stores a crafted attachment path, and the deletion handler later joins that path to the upload directory; the file deletion check limits paths to the application root rather than the upload directory.

Exploit preconditions

  • Attack surface: Comment administration endpoints and filesystem deletion
  • Required access: An authenticated administrator able to submit comment edits
  • Trigger point: Deletion of a comment containing the stored attachment path
  • Why exploitation is possible: The edit handler does not validate path containment, and the deletion check permits paths within the application root rather than restricting them to the upload directory

Why this happens

The handlers manipulate a user-controlled attachment path without canonicalizing and validating that the resolved path remains within the intended upload directory. This is a path traversal weakness mapped to CWE-22: Improper Limitation of a Pathname to a Restricted Directory. Checking against a broader application root does not enforce the narrower upload-directory boundary.

Potential impact

  • Application files, including configuration files, could be deleted
  • The CMS may become unavailable or fail to operate correctly
  • Administrators may need to restore deleted files from backups

General mitigation guidance

Defensive patterns should ensure file operations remain within their intended directory boundaries.

  • Resolve and canonicalize paths, then verify they are contained within the specific upload directory
  • Prefer server-generated file identifiers over accepting filesystem paths from request data
  • Validate attachment references against trusted records before deletion
  • Apply least-privilege filesystem permissions so the web application cannot delete unrelated application files
  • Treat authenticated input as untrusted and use safe-by-default file handling APIs

How teams detect issues like this

  • Use static analysis to identify path joins involving request data and file deletion APIs
  • Review code for fixed-length prefix removal or other path transformations without containment checks
  • Add tests and code-review checks that verify resolved file paths cannot escape the designated upload directory
  • Enforce policies requiring canonical path validation before filesystem operations

Sources

SourceLink
github.comgithub.com/nukeviet/nukeviet/commit/27ba63c32eea2782837b1464a930baf75f0b4d29
github.comgithub.com/nukeviet/nukeviet/releases/tag/4.5.09
github.comgithub.com/nukeviet/nukeviet/security/advisories/GHSA-c9xg-64p9-f2jj

Frequently asked

questions

Exploitation uses the CMS comment administration workflow and requires an authenticated administrator to submit the crafted attachment value.

The attacker needs permission to edit comments through the administrative interface and have the affected comment deleted afterward.

Canonicalize the target path and verify it is contained within the intended upload directory before performing any file operation.

Avoid trusting user-supplied filesystem paths, use server-controlled attachment references, and apply least-privilege filesystem permissions.

Find out what's already
exploitable in your codebase.