Traccar server can authenticate users via external LDAP server. Authentication process happens in two steps:
- Traccar connects to LDAP server with service credentials and lookup provided login/email with configured filter
- If user found and he is only one, traccar tries to authenticate on LDAP server with founded full Distinguished Name and provided password
If both steps are successful, user considered authenticated
There is still internal traccar user representation, it is created on first user login. Server administrator can configure adminGroup/adminFilter to automatically give user admin rights when he is created.
- ldap.enable - Main switch.
- ldap.url - Full connection url to LDAP server. If it is ommited next two parameters will be used to connect to server.
- ldap.server - LDAP server name.
- ldap.port - LDAP server port. Default is 389.
- ldap.base - Search base. Used to limit search scope with some OU.
- ldap.idAttribute - LDAP user attribute used to uniquely identify user in catalog. Default is uid. For Active Directory sAMAccountName usually should be used.
- ldap.nameAttribute - LDAP user attribute used to fill name field in traccar representation. Default is cn.
- ldap.mailAttribute - LDAP user attribute used to fill email field in traccar representation. Default is mail.
- ldap.searchFilter - LDAP filter to search users in catalog. Must contain :login substring which will be replaced with provided login/email when lookup. If parameter is omitted search will happen by simple equality idAttribute to provided login/email.
- ldap.adminFilter - LDAP filter to determine if user is traccar admin. Must contain :login substring which will be replaced with provided login/email when lookup. If parameter is omitted but ldap.adminGroup is defined members of this group will be traccar admins. If both are missed users will not be automatically promoted to traccar admins.
- ldap.user - Service user name used to lookup other users in catalog. Usually full Distinguished Name should be defined here.
- ldap.password - Password for service user.
- ldap.force - Disables internal authentication, only LDAP users can login.
Search filter to login in Active Directory by either login or email
According to next filter user must be member of Traccar users group or its nested groups (!) and not disabled. It is valid for Active Directory.