CVE-2026-59368: LdapQueryBuilder Silently Discards Existing Filter When Built From Another Query in Spring LDAP

Published Dec 2, 2026
·
Updated

LdapQueryBuilder can lose a search filter that an application expects to be enforced, causing an LDAP search to run with broader criteria than intended.

When a builder is created from an existing query, the filter carried over from that query is not treated as established. A later call that specifies a filter then replaces the carried-over filter instead of being rejected, so the original criteria are dropped without any error. The fix turns this into an IllegalStateException .

Preconditions :

The application derives one LdapQueryBuilder from another query and then specifies a further filter on the derived builder The dropped filter is what restricts the search, for example to a single tenant, organizational unit, or set of entries When the dropped filter was acting as an authorization boundary, an authenticated user can read directory entries outside the scope the application intended.

Affected Software

1 affected component
Spring Spring LDAP

Event History

Dec 2, 2026
CVE Published
via MITRE·07:10 AM
Data Sourced
via MITRE·07:10 AM
DescriptionSeverity

Frequently Asked Questions

1

Which applications are exposed to unintended LDAP result disclosure?

Applications are exposed if they create an LdapQueryBuilder from an existing query and then set another filter on the derived builder. The impact is significant when the original filter limits results by tenant, organizational unit, entry set, or another authorization boundary.

2

What access does an attacker need to exploit this behavior?

An attacker needs authenticated access as a user able to invoke the affected LDAP search path. No user interaction is required, but the application must execute a query construction flow that drops the intended restrictive filter.

3

How can teams identify potentially affected code?

Review uses of LdapQueryBuilder that are initialized from an existing query, then check whether the derived builder subsequently receives a filter specification. Determine whether the inherited filter was intended to restrict visibility or enforce authorization scope.

4

What changes after the fix is applied?

Rather than silently replacing the filter inherited from the original query, the affected query-building sequence raises an IllegalStateException. Applications using this pattern may therefore need code changes to avoid specifying a further filter on the derived builder.

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