0
votes

Can someone point me to documentation and/or describe what the LDAP configuration options mean for gerrit's configuration?

Ex: ou= and dc= etc.

I found these details on google's site about ldap configuration for accountBase and groupBase however it too lacks details about what the options/parameters are and what their values should be based on.

https://gerrit-review.googlesource.com/Documentation/config-gerrit.html#ldap

Luckily I blindly copied a co-worker's gerrit server configuration, he's using version 2.1.x. Initially I thought his options were different due to version differences, but then I tried adding his extra fields and my unique ldap account worked with the additional 'ou=' and additional 'dc=' parameters. Error, bad-config and good-config below.

Note: Our company has a single ldap server, but my co-worker's gerrit has a separate ldap log-in than mine. I didn't copy his log-in to get mine working, it was simply the accountBase and groupBase options that made the difference.

Error:

cat log/error_log | tail -n 1
[2015-12-16 17:21:24,144] INFO  com.google.gerrit.httpd.auth.ldap.LdapLoginServlet : 'cxxxxt\myaccount' failed to sign in: No such user: cxxxxt\myaccount

Bad config:

[ldap]
        server = ldap://crcxxxxt.rxxxxxxxxxxxxxs.com
        username = [email protected]
        accountBase = DC=rxxxxxxxxxxxxxs,DC=com
        groupBase = DC=rxxxxxxxxxxxxxs,DC=com

Good config:

[ldap]
        server = ldap://crcxxxxt.rxxxxxxxxxxxxxs.com
        username = [email protected]
        accountBase = ou=Cxxxxxs,dc=cxxxxt,dc=rxxxxxxxxxxxxxs,dc=com
        groupBase = ou=Cxxxxxs,dc=cxxxxt,dc=rxxxxxxxxxxxxxs,dc=com
1
These settings depend on your LDAP server's structure, not on Gerrit.StephenKing

1 Answers

0
votes

http://www.ldapman.org/articles/intro_to_ldap.html

This page describes ou= as organizational unit and dc= as domain components. I'll confirm these with my IT's LDAP configuration settings after the holidays.

Gerrit's site mentions what the separate row/options are but doesn't describe what the syntax of each line should be or what the options are for. For most configuration topics which aren't covered by gerrit's site, external links are provided. This was the only one I found missing for my chosen configuration.