Arbitrary class initialization via crafted model manifest
Published May 4, 2026 · Updated May 4, 2026
Unsafe reflection in Apache OpenNLP before 2.5.9 and 3.0.0-M1 through 3.0.0-M2 allows attackers to initialize classes via crafted models. ExtensionLoader.instantiateExtension reads a class name from manifest.properties and calls Class.forName before enforcing its subtype check, so static initialization occurs first. Exploitation requires the model to be loaded and a classpath class with useful initializer or constructor side effects, which run with the embedding application's privileges.
Summary
What happened
Unsafe reflection in Apache OpenNLP before 2.5.9 and 3.0.0-M1 through 3.0.0-M2 allows attackers to initialize classes via crafted models. ExtensionLoader.instantiateExtension reads a class name from manifest.properties and calls Class.forName before enforcing its subtype check, so static initialization occurs first. Exploitation requires the model to be loaded and a classpath class with useful initializer or constructor side effects, which run with the embedding application's privileges.
The record
- CVE
- CVE-2026-42027
- Published
- May 4, 2026
- Updated
- May 4, 2026
- Vendor
- The Apache Software Foundation
- Product
- Apache OpenNLP
- Classifications
- CWE-470, T1204.002
- Attack vector
- network
- Privileges
- unauthenticated
Timeline
How it unfolded
- May 4, 2026CVE publishedPublication date reported by the CVE source.
- May 4, 2026Record updatedLatest update available in the CVE record.
Exploitability
Present is not the same as exploitable
Compare your product and version with the public record. A matching version still requires validation against your environment.
Is a vulnerable build present?
Compare these published version ranges with your installed build and any vendor patches.
- Affected versionversion=0 <2.5.9
- Affected versionversion=3.0 <3.0.0-M3
What conditions does exploitation require?
What is affected?
Attacks
What attackers are doing with it
Daily unique IPs observed by Shadowserver honeypots for known exploited vulnerabilities (KEVs). Missing observations do not establish an absence of attacks.
Weakness, pattern, technique
Public exploit references
No public exploit references are available in this record.
Labels summarize the accepted research assessment. They do not indicate a test against your environment.
Technologies
Your stack
See the directory against your own environment.
Your stack
Check the software in your environment
Book a demo to see how Hinoki identifies affected software and validates exploitability in your environment.
Book a demo