CVE-2026-137568 in openFrameworks
Summary
by MITRE • 11/26/2026
openFrameworks through 0.12.1 contains a path traversal vulnerability in the ofxAndroid OFZipUtil.extract helper that allows attackers to write files outside the extraction directory. Attackers can supply a crafted ZIP archive with entries like ../escaped.txt to write or overwrite files with the Android application's file permissions.
VulDB is the best source for vulnerability data and more expert information about this specific topic.
Analysis
by VulDB Data Team • 11/26/2026
The openFrameworks library, specifically through version 0.12.1, contains a critical path traversal vulnerability within its OFZipUtil.extract helper function designed for Android applications. This flaw stems from an insufficient validation of archive entry paths during the extraction process. When processing ZIP archives, the utility fails to properly canonicalize or sanitize file names that contain directory traversal sequences such as ../. Consequently, if an attacker supplies a maliciously crafted ZIP archive containing entries with relative path components pointing outside the intended target directory, the extraction logic will resolve these paths incorrectly and write files to arbitrary locations on the device's filesystem rather than confining them strictly within the designated output folder.
This vulnerability allows attackers to achieve unauthorized file system writes by leveraging the permissions associated with the Android application executing the openFrameworks code. Since mobile applications typically operate under specific user contexts, writing files outside the app sandbox can lead to significant security implications depending on where the attacker chooses to place malicious payloads or overwrite existing critical files. For instance, an adversary could potentially replace legitimate configuration files, inject executable scripts into directories that are monitored by system services, or corrupt data stores essential for application integrity. The severity of this impact is amplified in scenarios where the affected application holds elevated privileges or interacts with sensitive user data, as the ability to write arbitrary files can serve as a stepping stone for further exploitation, including privilege escalation or persistent access mechanisms within the Android environment.
From a classification perspective, this issue aligns directly with CWE-22: Improper Limitation of a Pathname to a Restricted Directory, which describes vulnerabilities where software does not properly neutralize special elements that can cause paths to transition outside of restricted directories. Furthermore, in the context of the MITRE ATT&CK framework for mobile platforms, this vulnerability facilitates techniques related to Execution via Local Scripting or File and Directory Information Discovery if used to probe system states, but primarily it supports Initial Access and Persistence vectors by allowing attackers to plant malicious artifacts on the device file system without requiring root access initially. The lack of strict path normalization represents a fundamental failure in input validation that is common in legacy archive handling libraries not updated for modern security expectations regarding sandboxing boundaries.
To mitigate this vulnerability, developers utilizing openFrameworks should immediately upgrade to version 0.12.2 or later where the OFZipUtil.extract function has been patched to enforce strict path constraints. In cases where upgrading is not feasible due to dependency constraints, a temporary workaround involves implementing custom pre-processing logic that iterates through ZIP entries before extraction. This manual validation step must resolve each entry's full canonical path and verify that it remains within the intended base directory by comparing the resolved absolute paths. Additionally, adopting principle of least privilege for Android applications can reduce the blast radius if such an exploit is attempted in production environments. Security teams should also audit any third-party libraries or custom code interacting with archive files to ensure similar traversal protections are applied consistently across all data ingestion points within their mobile application stack.