Apache Karaf builds LDAP search filters in LDAPCache and LDAPBackingEngine by substituting login name, user DN, and fully qualified name placeholders (%u, %dn, %fqdn) into administrator-configured userFilter and roleFilter templates. Before the fix, the substituted value was only backslash-escaped, so RFC 4515 metacharacters such as *, (, ), and NUL were not escaped and a crafted name could change the filter structure, widen results, match a different LDAP entry, or over-grant roles. The bug is not reachable through LDAPLoginModule or LDAPPubkeyLoginModule, which already apply correct RFC 4515 encoding, but it is reachable when GSSAPILdapLoginModule or LDAPBackingEngine listRoles pass a name through unescaped. Deployments that use those JAAS LDAP paths with custom filter templates are the ones at risk. There is no known public proof of concept and it is not listed in CISA KEV.
What to do: Upgrade Apache Karaf to a release that includes the vendor fix for CVE-2026-90979 as soon as it is available. Until then, inventory JAAS configs that use GSSAPILdapLoginModule or LDAPBackingEngine role lookup (listRoles), and treat login and principal names as untrusted filter input. Prefer the login modules that already apply RFC 4515 escaping (LDAPLoginModule and LDAPPubkeyLoginModule) and review userFilter and roleFilter templates for overly broad matches.
Affected
Apache Karaf (JAAS LDAPCache and LDAPBackingEngine)
—
Estimated exposure
—No basis for an estimate.
Order-of-magnitude estimate by the model from install counts, market share and public scan data it knows; verify before quoting.
Description
LDAPCache and LDAPBackingEngine build LDAP search filters for user lookup and role lookup by textually substituting the placeholders %u, %dn, and %fqdn (drawn from the login name, the resolved user DN, and its fully qualified namespace form) into administrator-configured filter templates (userFilter, roleFilter). Before the fix, the only sanitization applied to the substituted value was double backslashed: filter = filter.replaceAll(Pattern.quote("%u"), Matcher.quoteReplacement(user)); filter = filter.replace("\\", "\\\\"); This does not escape the other characters RFC 4515 requires escaping in an LDAP search filter: *, (, ), and NUL. A login name containing any of these can change the structure of the resulting filter rather than being matched as a literal value (e.g. a crafted username can turn an equality match into a wildcard match, or close/reopen filter clauses), widening what the search returns and potentially causing a login or role lookup to match an LDAP entry other than the intended one, over-granting roles, and depending on deployment-specific filter templates, potentially affecting which account a login resolved to. It's not exploitable through every entry points: LDAPLoginModule and LDAPPubkeyLoginModule both called Util.doRFC2254Encoding() (correct RFC 4515 escaping) on the login name before handing it to LDAPCache, which masked the missing escaping in LDAPCache for those two call paths. Using LDAPCache directly (bypassing the login modules) does not reproduce through the normal LDAPLoginModule/LDAPPubkeyLoginModule authentication flow for this reason. It does reproduce through two other call paths that reach LDAPCache/LDAPBackingEngine without any prior escaping: * GSSAPILdapLoginModule passes the NameCallback name straight through, unescaped. * LDAPBackingEngine (listRoles) passes principal.getName() straight through, unescaped.
Apache Karaf before 4.4.12 has a moderate LDAP filter injection flaw in its JAAS login modules.
Jean-Baptiste Onofré disclosed CVE-2026-90979, rated moderate, in Apache Karaf JAAS LDAP modules before 4.4.12. LDAPCache and LDAPBackingEngine build user and role search filters by substituting %u, %dn, and %fqdn into administrator-configured userFilter and roleFilter templates. Those values come from the login name, the resolved user DN, and its fully qualified namespace form. The post does not describe in-the-wild exploitation.