CVE-2023-40274
Rust vulnerability analysis and mitigation

Overview

An issue was discovered in zola 0.13.0 through 0.17.2. The custom implementation of a web server, available via the "zola serve" command, allows directory traversal. The handle_request function, used by the server to process HTTP requests, does not account for sequences of special path control characters (../) in the URL when serving a file, which allows one to escape the webroot of the server and read arbitrary files from the filesystem (NVD).

Technical details

The vulnerability exists in the handle_request function within zola/src/cmd/serve.rs. The application only checks for a trusted path prefix but does not fully resolve the path. Since the webroot directory is prepended to each path, the security check can be bypassed as the path still starts with the trusted prefix even when using path traversal sequences. The CVSS v3.1 base score is 7.5 HIGH with vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N (NVD, GitHub Issue).

Impact

The vulnerability allows attackers to read arbitrary files from the filesystem of machines running the zola serve command. This could lead to exposure of sensitive system files and information disclosure (GitHub Issue).

Mitigation and workarounds

The vulnerability has been patched by using fs canonicalize to prevent path traversal attacks. Users should upgrade to a version after 0.17.2 that includes this fix (GitHub PR).

Additional resources


SourceThis report was generated using AI

Related Rust vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-22257HIGH8.8
  • RustRust
  • salvo
NoYesJan 08, 2026
CVE-2026-22698HIGH8.7
  • RustRust
  • sm2
NoNoJan 10, 2026
CVE-2026-22699HIGH7.5
  • RustRust
  • sm2
NoNoJan 10, 2026
GHSA-g59m-gf8j-gjf5LOW3.7
  • RustRust
  • aws-sdk-controlcatalog
NoYesJan 08, 2026
GHSA-585q-cm62-757jLOW2
  • RustRust
  • mnl
NoNoJan 09, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management