User search mode and user DN templates mode

edit

See Configuring an LDAP realm.