org.apache.opennlp:opennlp-tools@2.5.8

  • latest version

    2.5.9

  • latest non vulnerable version

  • first published

    15 years ago

  • latest version published

    14 days ago

  • licenses detected

  • package registry

  • Direct Vulnerabilities

    Known vulnerabilities in the org.apache.opennlp:opennlp-tools package. This does not include vulnerabilities belonging to this package’s dependencies.

    Fix vulnerabilities automatically

    Snyk's AI Trust Platform automatically finds the best upgrade path and integrates with your development workflows. Secure your code at zero cost.

    Fix for free
    VulnerabilityVulnerable Version
    • H
    Memory Allocation with Excessive Size Value

    org.apache.opennlp:opennlp-tools is an is a machine learning based toolkit for the processing of natural language text.

    Affected versions of this package are vulnerable to Memory Allocation with Excessive Size Value in the AbstractModelReader class. An attacker can cause the application to exhaust system memory and crash by supplying a crafted .bin model file with manipulated count fields that trigger unbounded array allocations during deserialization.

    Note:

    This is only exploitable if the application loads model files from untrusted or semi-trusted sources.

    How to fix Memory Allocation with Excessive Size Value?

    Upgrade org.apache.opennlp:opennlp-tools to version 2.5.9, 3.0.0-M3 or higher.

    [,2.5.9)[3.0.0-M1,3.0.0-M3)
    • H
    XML External Entity (XXE) Injection

    org.apache.opennlp:opennlp-tools is an is a machine learning based toolkit for the processing of natural language text.

    Affected versions of this package are vulnerable to XML External Entity (XXE) Injection via the create() method in the DictionaryEntryPersistor class, which initializes a SAXParserFactory without enabling FEATURE_SECURE_PROCESSING or disabling DTD processing. An attacker can access local files or send server-side requests by supplying a dictionary file containing malicious DOCTYPE declarations.

    How to fix XML External Entity (XXE) Injection?

    Upgrade org.apache.opennlp:opennlp-tools to version 2.5.9 or higher.

    [,2.5.9)
    • H
    Unsafe Reflection

    org.apache.opennlp:opennlp-tools is an is a machine learning based toolkit for the processing of natural language text.

    Affected versions of this package are vulnerable to Unsafe Reflection that leads to arbitrary class instantiation, via the instantiateExtension() method in the ExtensionLoader class. An attacker can trigger the static initializer of any class present on the classpath by supplying a model archive with a malicious manifest, leading to the execution of unintended code with potential side effects such as JNDI lookups, outbound network requests, or filesystem access. The isAssignableFrom() check that is intended to block the loading of classes from outside the extension's namespace succeeds, but runs after the class has already been loaded and initialized.

    This is only exploitable if a class with attacker-controlled side effects in its static initializer or no-argument constructor is present on the classpath, and the attacker is able to supply a model archive from an untrusted source, such as a shared Hugging Face model.

    Note: The fix for this vulnerability involves an allowlist approach, a consequence of which is that classes under the opennlp.* prefix are permitted by default. Other classes must be explicitly allowed via registerAllowedPackage() or configured with OPENNLP_EXT_ALLOWED_PACKAGES

    How to fix Unsafe Reflection?

    Upgrade org.apache.opennlp:opennlp-tools to version 2.5.9 or higher.

    [,2.5.9)