Skip to content
Snippets Groups Projects
Commit e7513e59 authored by Henrik tom Wörden's avatar Henrik tom Wörden
Browse files

FIX: allow ldap server and domain to be different

parent 0f0e54e1
Branches
Tags
No related merge requests found
# This file is sourced by the LDAP authentication script # This file is sourced by the LDAP authentication script
# Set the ldap server here.
# Set the ldap server here. This is also used to generate a fully qualified
# user name: <USER>@$LDAP_SERVER
# LDAP_SERVER="example.com" # LDAP_SERVER="example.com"
# Set the ldap domain here. This is used to generate a fully qualified
# user name: <USER>@$LDAP_DOMAIN
# LDAP_DOMAIN="example.com"
...@@ -35,7 +35,7 @@ exe_dir=$(dirname $0) ...@@ -35,7 +35,7 @@ exe_dir=$(dirname $0)
# If the second argument is empty or "-", take password from stdin, else use the argument as a file. # If the second argument is empty or "-", take password from stdin, else use the argument as a file.
testpw() { testpw() {
username="${1}@${LDAP_SERVER}" username="${1}@${LDAP_DOMAIN}"
pwfile="$2" pwfile="$2"
pwargs=("-w" "$pwfile") pwargs=("-w" "$pwfile")
if [[ $pwfile == "-" ]] ; then if [[ $pwfile == "-" ]] ; then
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment