CVE-2025-5878: ESAPI esapi-java-legacy SQL Injection Defense Encoder.encodeForSQL special element

Published Jun 29, 2025
·
Updated

A vulnerability was found in ESAPI esapi-java-legacy and classified as problematic. This issue affects the interface Encoder.encodeForSQL of the SQL Injection Defense. An attack leads to an improper neutralization of special elements. The attack may be initiated remotely and an exploit has been disclosed to the public. The project was contacted early about this issue and handled it with an exceptional level of professionalism. Upgrading to version 2.7.0.0 is able to address this issue. Commit ID f75ac2c2647a81d2cfbdc9c899f8719c240ed512 is disabling the feature by default and any attempt to use it will trigger a warning. And commit ID e2322914304d9b1c52523ff24be495b7832f6a56 is updating the misleading Java class documentation to warn about the risks.

Affected Software

1 affected component
ESAPI esapi-java-legacy<2.7.0.0

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade ESAPI esapi-java-legacy to a version that resolves this vulnerability.

    Fixed in 2.7.0.0
  2. Configuration

    Disable the Encoder.encodeForSQL feature by default; attempts to use it should trigger a warning.

    ESAPI esapi-java-legacy SQL Injection Defense Encoder.encodeForSQL = disabled by default

Event History

Jun 29, 2025
CVE Published
via MITRE·11:11 AM
Data Sourced
via MITRE·11:11 AM
DescriptionSeverityWeakness
Data Sourced
via NVD·12:15 PM
DescriptionSeverityWeakness
Event
via NVD·12:15 PM

Frequently Asked Questions

1

What is the severity of CVE-2025-5878?

CVE-2025-5878 is classified as problematic due to its potential exploitation through SQL injection.

2

How do I fix CVE-2025-5878?

To resolve CVE-2025-5878, upgrade ESAPI esapi-java-legacy to version 2.7.0.0 or later.

3

What software is affected by CVE-2025-5878?

CVE-2025-5878 affects ESAPI esapi-java-legacy versions prior to 2.7.0.0.

4

Can CVE-2025-5878 be exploited remotely?

Yes, CVE-2025-5878 can be exploited remotely by an attacker.

5

What kind of attacks can CVE-2025-5878 facilitate?

CVE-2025-5878 facilitates SQL injection attacks due to improper neutralization of special elements.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203