diff options
author | Ismaël Bouya <ismael.bouya@normalesup.org> | 2019-01-25 23:23:44 +0100 |
---|---|---|
committer | Ismaël Bouya <ismael.bouya@normalesup.org> | 2019-01-25 23:41:01 +0100 |
commit | bad8f8d3cfaf48e6693f9718857a4648a86b0d37 (patch) | |
tree | 07592e653d96aa9e693ef609aadc64e5adccabe4 /nixops/modules | |
parent | 01f21083a897b86bf148f1d2bb9c8edca4d3786a (diff) | |
download | Nix-bad8f8d3cfaf48e6693f9718857a4648a86b0d37.tar.gz Nix-bad8f8d3cfaf48e6693f9718857a4648a86b0d37.tar.zst Nix-bad8f8d3cfaf48e6693f9718857a4648a86b0d37.zip |
Add startTLS when using ldapsearch
Fixes https://git.immae.eu/mantisbt/view.php?id=98
Diffstat (limited to 'nixops/modules')
-rwxr-xr-x | nixops/modules/gitolite/gitolite_ldap_groups.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/nixops/modules/gitolite/gitolite_ldap_groups.sh b/nixops/modules/gitolite/gitolite_ldap_groups.sh index 5f7ef6d..7db0da4 100755 --- a/nixops/modules/gitolite/gitolite_ldap_groups.sh +++ b/nixops/modules/gitolite/gitolite_ldap_groups.sh | |||
@@ -7,7 +7,7 @@ ldap_bindpw="$LDAP_PASS" | |||
7 | ldap_searchbase="dc=immae,dc=eu" | 7 | ldap_searchbase="dc=immae,dc=eu" |
8 | ldap_scope="subtree" | 8 | ldap_scope="subtree" |
9 | 9 | ||
10 | ldap_options="-h ${ldap_host} -x -D ${ldap_binddn} -w ${ldap_bindpw} -b ${ldap_searchbase} -s ${ldap_scope}" | 10 | ldap_options="-h ${ldap_host} -ZZ -x -D ${ldap_binddn} -w ${ldap_bindpw} -b ${ldap_searchbase} -s ${ldap_scope}" |
11 | 11 | ||
12 | ldap_filter="(&(memberOf=cn=groups,cn=gitolite,ou=services,dc=immae,dc=eu)(|(member=uid=${uid_param},ou=users,dc=immae,dc=eu)(member=uid=${uid_param},ou=group_users,dc=immae,dc=eu)))" | 12 | ldap_filter="(&(memberOf=cn=groups,cn=gitolite,ou=services,dc=immae,dc=eu)(|(member=uid=${uid_param},ou=users,dc=immae,dc=eu)(member=uid=${uid_param},ou=group_users,dc=immae,dc=eu)))" |
13 | ldap_result=$(ldapsearch ${ldap_options} -LLL "${ldap_filter}" cn | grep 'cn:' | cut -d' ' -f2) | 13 | ldap_result=$(ldapsearch ${ldap_options} -LLL "${ldap_filter}" cn | grep 'cn:' | cut -d' ' -f2) |