Description
Rust OneNote File Parser is a parser for Microsoft OneNote files implemented in Rust. Prior to version 1.1.1, a maliciously crafted `.onetoc2` table-of-contents file can cause `Parser::parse_notebook` to open arbitrary files on the host filesystem outside the notebook's directory. The parser reads entry names listed inside the `.onetoc2` and joins them against the notebook's base directory without validating that they are relative paths confined to that directory. The parser will bail out when the target file fails to parse as a OneNote section, so direct content exfiltration through the parser's return value is not practical, though file-existence probing and denial-of-service via large or special files remain possible. Anyone using `onenote_parser` to parse .onetoc2 files received from untrusted sources is affected. Users who only ever parse their own notebooks are not at meaningful risk. The issue is fixed in onenote_parser 1.1.1. The fix rejects absolute paths, parent-directory components, and other invalid path characters in entry names, and additionally canonicalises the resolved path to confirm it stays inside the notebook's base directory. For users who cannot upgrade to 1.1.1, only call `Parser::parse_notebook` on `.onetoc2` files from trusted sources. Alternatively, use `Parser::parse_section` / `Parser::parse_section_buffer` on individual .one files, which do not perform the directory walk.
Published: 2026-07-20
Score: 4.4 Medium
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

The vulnerability occurs when the Rust OneNote parser reads a maliciously crafted .onetoc2 file that contains entry names combined with the notebook base directory without validation, allowing path traversal. The parser joins the entry names to the base path, so absolute or parent‑directory components are not rejected. Although the parser will fail to parse a file that is not a valid OneNote section and therefore does not return its contents, it still permits an attacker to probe whether arbitrary files exist on the host filesystem and can trigger denial‑of-service by pointing to large or specially crafted files. This issue affects any use of onenote_parser 1.0.x–1.1.0 that parses .onetoc2 files from untrusted sources; users who only parse locally created notebooks are not at meaningful risk. The flaw is fixed in onenote_parser 1.1.1, which rejects absolute paths, parent‑directory components, and invalid path characters, and canonicalises the resolved path to ensure it remains inside the notebook’s base directory.

Affected Systems

All users of the onenote_parser crate from the source repository msiemens:onenote.rs that rely on the Parser::parse_notebook function and are using a version earlier than 1.1.1 are potentially affected. This includes any Rust projects that import the crate and parse .onetoc2 files received from external or untrusted sources. Projects that only parse notebooks created locally or that never use the parse_notebook entry point are not at meaningful risk.

Risk and Exploitability

The CVSS score is 4.4, indicating a moderate severity. The EPSS score is available and is < 1%, denoting a very low probability of exploitation. The vulnerability is not listed in KEV. The likely attack vector is an attacker supplying a malicious .onetoc2 file to a running application that uses Parser::parse_notebook. Because the function performs a directory walk, the attack requires the attacker to deliver the crafted table‑of‑contents file to the application’s local environment; network exposure is not required. The risk is mitigated if the parser is updated to a newer version that rejects absolute or parent‑directory components and validates path containment.

Generated by OpenCVE AI on July 30, 2026 at 19:12 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade onenote_parser to version 1.1.1 or newer, which rejects absolute, parent‑directory, and invalid path components and checks that the resolved path stays inside the notebook base directory.
  • If an upgrade is not possible, ensure that Parser::parse_notebook is only called on .onetoc2 files that originate from trusted sources and never from untrusted input.
  • Alternatively, process individual .one files using Parser::parse_section or Parser::parse_section_buffer, which do not perform the directory walk and therefore cannot be used to traverse outside the notebook directory.

Generated by OpenCVE AI on July 30, 2026 at 19:12 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-4j5m-wc25-pvh7 Rust OneNote File Parser: Path traversal in `Parser::parse_notebook` allows reading files outside the notebook directory
History

Thu, 23 Jul 2026 21:45:00 +0000

Type Values Removed Values Added
First Time appeared Msiemens
Msiemens onenote.rs
Vendors & Products Msiemens
Msiemens onenote.rs

Mon, 20 Jul 2026 18:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}


Mon, 20 Jul 2026 16:15:00 +0000

Type Values Removed Values Added
Description Rust OneNote File Parser is a parser for Microsoft OneNote files implemented in Rust. Prior to version 1.1.1, a maliciously crafted `.onetoc2` table-of-contents file can cause `Parser::parse_notebook` to open arbitrary files on the host filesystem outside the notebook's directory. The parser reads entry names listed inside the `.onetoc2` and joins them against the notebook's base directory without validating that they are relative paths confined to that directory. The parser will bail out when the target file fails to parse as a OneNote section, so direct content exfiltration through the parser's return value is not practical, though file-existence probing and denial-of-service via large or special files remain possible. Anyone using `onenote_parser` to parse .onetoc2 files received from untrusted sources is affected. Users who only ever parse their own notebooks are not at meaningful risk. The issue is fixed in onenote_parser 1.1.1. The fix rejects absolute paths, parent-directory components, and other invalid path characters in entry names, and additionally canonicalises the resolved path to confirm it stays inside the notebook's base directory. For users who cannot upgrade to 1.1.1, only call `Parser::parse_notebook` on `.onetoc2` files from trusted sources. Alternatively, use `Parser::parse_section` / `Parser::parse_section_buffer` on individual .one files, which do not perform the directory walk.
Title Rust OneNote File Parser: Path traversal in `Parser::parse_notebook` allows reading files outside the notebook directory
Weaknesses CWE-22
References
Metrics cvssV3_1

{'score': 4.4, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:L/I:N/A:L'}


Subscriptions

Msiemens Onenote.rs
cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-07-20T17:31:57.487Z

Reserved: 2026-05-15T21:46:51.547Z

Link: CVE-2026-46671

cve-icon Vulnrichment

Updated: 2026-07-20T17:31:54.016Z

cve-icon NVD

No data.

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-07-30T19:15:04Z

Weaknesses
  • CWE-22

    Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')