Executive brief
ORAS Java is a library used to interact with OCI registries for managing container artifacts. A vulnerability in the way it handles file names during artifact downloads allows a malicious registry to write files to arbitrary locations on the user's system. This could lead to the overwriting of critical system files or the placement of malicious code, potentially compromising the entire application or server.
Technical details
A path traversal vulnerability exists in the `pullArtifact` methods of the `Registry` and `OCILayout` classes in ORAS Java. The library uses the `org.opencontainers.image.title` annotation from a pulled manifest as a filename without performing normalization or containment checks. By providing a title containing absolute paths or parent directory references (e.g., `../../`), an attacker-controlled registry can force the SDK to write or overwrite files anywhere the JVM process has write permissions. This issue is specifically present in the non-unpacking branch of `pullLayer` and in `OCILayout.pullArtifact`. The vulnerability is addressed in version 0.6.2.
Affected products
- ORAS Project oras-java-sdk <= 0.6.1
Timeline
- 2026-05-13: disclosed: Advisory published by reporter on GitHub
- 2026-05-19: advisory: GitHub Advisory reviewed and published
- 2026-05-19: patched: Fix available in version 0.6.2