Last active
August 26, 2021 11:30
-
-
Save bendem/9dafd6d2972a080861bb09faaae2e9e5 to your computer and use it in GitHub Desktop.
Some useful ldap commands
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ldapsearch -LLL -o ldif-wrap=no -H ldapi:/// -Y EXTERNAL -b 'cn=config' 'olcAccess=*' olcAccess \ | |
| awk '{ | |
if ($1 == "olcAccess::") { | |
command = "base64 -d -i"; print $2 | command; close(command) | |
} else { | |
print $0 | |
} | |
}' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ldapmodify -H ldapi:/// -Y EXTERNAL <<EOF | |
dn: cn=config | |
changetype: modify | |
replace: olcLogLevel | |
olcLogLevel: config stats acl | |
EOF |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment