Sonar 8.9.5 LDAP configuration


we migrated today from sonar 7.9.2 to sonar 8.9.5 which overall went smoothly.
But we now face the issue that Users cant Login through LDAP anymore.
In the logs we can see that it looks like it doesn’t even try to use LDAP:

2022.01.31 12:30:17 DEBUG web[******][auth.event] login failure [cause|User must be authenticated][method|BASIC][provider|LOCAL|local][IP|******|*********][login|]

For e.g on our test Instance with the same Version and similar configuration (identical File and same LDAP Server and search string) we can see that the LDAP is used to authenticate the user:

2022.01.31 13:16:09 DEBUG web[********][auth.event] login success [method|FORM][provider|REALM|LDAP][IP|*****|][login|*****]

Would appreciate any hints because currently we are out of ideas.

Thank You!

Hey there.

An issue can occur if you are using the following properties deprecated in SonarQube v8.1 and now removed.

  • ldap.user.objectClass
  • ldap.user.loginAttribute

If this applies to you, you should remove the deprecated properties and update the existing LDAP request properties (ldap.user.* and*).

Hi Colin,

thank you for the fast response. As far as i can see we dont use any of the deprecate properties:

# LDAP configuration
# General Configuration

# User Configuration

Is there any way to check if LDAP is being used at all? We don’t see any mention of LDAP in the logs during startup.

e.g on our Test instance we see this in the web.log:

2022.01.31 11:57:42 INFO  web[][o.s.a.l.LdapContextFactory] Test LDAP connection on ldaps://***: OK

We think we found our issue. When we check the /api/system/info there is no mention of LDAP.
Because we use the same system file we are pretty sure it is not a issue witth it. Is there a way to check if the bundled ldap plugin is starting/working?

Hey there,

LDAP authentication is built into the core of SonarQube in v8.9 LTS and not provided via plugin.

If you change anything else in your conf/ file and restart your server, are the changes reflected?