Merge pull request #341 from MelwinKfr/patch-1

add: LDAP options `bindUser` and `bindPassword`
This commit is contained in:
Roger Witzig 2017-10-11 13:34:31 +02:00 committed by GitHub
commit b30a9f2e41
2 changed files with 6 additions and 1 deletions

View file

@ -121,6 +121,9 @@ filter="(|(username={{username}})(mail={{username}}))"
#Username field in LDAP (uid/cn/username)
uidTag="username"
passwordresetlink=""
# Use a different user to bind LDAP (final bind DN will be: {{uidTag}}={{bindUser}},{{baseDN}})
bindUser=""
bindPassword=""
[postfixbounce]
# Enable to allow writing Postfix bounce log to Mailtrain listener

View file

@ -85,7 +85,9 @@ if (config.ldap.enabled && LdapStrategy) {
attributes: [config.ldap.uidTag, 'mail'],
scope: 'sub'
},
uidTag: config.ldap.uidTag
uidTag: config.ldap.uidTag,
bindUser: config.ldap.bindUser,
bindPassword: config.ldap.bindPassword
};
passport.use(new LdapStrategy(opts, (profile, done) => {