/

CVE-2026-28518

Severity:

HIGH RISK

(7.8)

Path Traversal in OpenViking

CVE-2026-28518

Analyzed

Vulnerability type

Category:

Path Traversal

CWE:

CWE-22

Impact:

Arbitrary File Write / Overwrite

Severity:

HIGH RISK

(7.8)

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

OpenViking up to version 0.2.1 contains a path traversal vulnerability in its .ovpack archive import logic, allowing crafted archive entries to escape the intended import directory.

An attacker who can supply a malicious .ovpack file may cause the application to create or overwrite arbitrary files on the filesystem with the importing process's privileges.

Affected context

The vulnerability arises when OpenViking processes .ovpack (ZIP-based) archives and extracts their contents onto the local filesystem.

If the application imports archives from user-controlled or otherwise untrusted sources, and does not strictly validate member paths, archive entries containing ../ traversal sequences, absolute paths, or drive-prefixed paths can bypass the intended import directory.

This behavior is particularly relevant in environments where OpenViking runs with elevated or service-level privileges and writes into shared or sensitive filesystem locations.

Exploit preconditions

  • Attack surface: The .ovpack import functionality that accepts ZIP-based archives.
  • Required access: Ability to supply or influence a .ovpack file that OpenViking imports (e.g., via user upload, sync, plugin feed, or local file placement).
  • Trigger point: The moment OpenViking processes the .ovpack archive and writes its members to disk.
  • Why exploitation is possible: The import code trusts the internal filenames in the archive and does not enforce that the resulting paths remain confined to the intended import directory, allowing traversal sequences, absolute paths, or drive prefixes to redirect writes to arbitrary locations.

Why this happens

This issue stems from insufficient sanitization and canonicalization of file paths during archive extraction, aligning with CWE-22: Improper Limitation of a Pathname to a Restricted Directory.

The .ovpack handler uses the member names from the ZIP archive directly when constructing output paths, without normalizing paths and verifying that the final resolved path is still within the target import directory.

As a result, crafted entries with ../ segments, leading slashes, or OS-specific drive prefixes can escape the intended directory and target arbitrary locations on the filesystem.

Potential impact

  • Overwriting application configuration files, potentially changing behavior or disabling security settings.
  • Creating new files in writable system or application directories that may later be executed or loaded.
  • Tampering with user data or project files managed by OpenViking.
  • Planting web-accessible files in webroot directories (in integrated deployments), which could enable secondary attacks.
  • Interfering with logs or other diagnostic files to obscure malicious activity.

General mitigation guidance

Mitigation generally focuses on constraining archive extraction to a well-defined directory and enforcing robust path validation:

  • Normalize and canonicalize each archive member path, then verify that the resolved path remains under the designated import root before writing.
  • Explicitly reject entries containing .., leading separators, absolute paths, or drive prefixes, regardless of platform.
  • Use APIs or helper routines designed for safe archive extraction that enforce directory confinement.
  • Run the OpenViking importing process with the least privileges necessary and restrict its filesystem write access to dedicated directories.
  • Treat external .ovpack files as untrusted input and combine file-level controls with broader OS-level sandboxing or containerization to limit damage from potential misuse.

How teams detect issues like this

Detection can combine code-level analysis and runtime monitoring:

  • Static analysis: Search for archive extraction code that concatenates user-controlled or archive-supplied paths with filesystem locations without normalization and boundary checks.
  • Code review: Examine .ovpack handling routines for:
  • Direct use of ZIP entry names when constructing filesystem paths.
  • Lack of checks for .., absolute paths, or drive prefixes.
  • Missing validation that the final resolved path is within the allowed import directory.
  • Runtime monitoring: Use filesystem auditing or monitoring tools to detect unexpected writes by the OpenViking process outside its designated data directories.
  • Policy enforcement: Incorporate secure archive-handling guidelines into development standards and CI checks, flagging unsafe path usage around extraction logic.

Sources

SourceLink
github.comgithub.com/volcengine/OpenViking/commit/46b3e76e28b9b3eee73693720c9ec48820228b72
github.comgithub.com/volcengine/OpenViking/issues/342
vulncheck.comvulncheck.com/advisories/openviking-ovpack-import-zip-slip-path-traversal

Frequently asked

questions

It can be, if OpenViking is exposed through a service or interface that accepts .ovpack files from remote users or automated feeds. If .ovpack files are only imported from local, trusted sources, the practical exposure is reduced but still dependent on who can place files on the system.

An attacker must be able to provide or influence a .ovpack archive that OpenViking imports. They do not need direct filesystem access; the vulnerability leverages the application's own write permissions to perform file creation or overwrite.

The most robust fix is to implement strict path normalization and enforcement: resolve each archive entry to an absolute path, confirm it remains within the intended import directory, and reject any entry that does not meet this constraint. Rejecting entries with traversal indicators, absolute paths, or drive prefixes is a key part of this pattern.

Treat all archive contents as untrusted, adopt a standard safe-extraction utility or library, and enforce a consistent rule that untrusted paths must be canonicalized and explicitly checked against allowed directories. Combine this with least-privilege execution and regular security-focused code reviews around file handling and import features.

Find out what's already
exploitable in your codebase.