Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/CISOfy/lynis.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Boelen <michael.boelen@cisofy.com>2016-09-10 17:12:44 +0300
committerMichael Boelen <michael.boelen@cisofy.com>2016-09-10 17:12:44 +0300
commit903016df362e39444d314a81dd4a0ebc61b67da0 (patch)
treee922e2e0039428dec461bfea52ff8e503720370a /include/tests_ldap
parent2534fb99a9dbc869fd90f0967c6917191b306b69 (diff)
Code cleanups and generic enhancements
Diffstat (limited to 'include/tests_ldap')
-rw-r--r--include/tests_ldap12
1 files changed, 6 insertions, 6 deletions
diff --git a/include/tests_ldap b/include/tests_ldap
index 0d940c5f..6c04a3bc 100644
--- a/include/tests_ldap
+++ b/include/tests_ldap
@@ -26,7 +26,7 @@
#
#################################################################################
#
- SLAPD_CONF_LOCS="/etc/ldap /etc/openldap /usr/local/etc/openldap"
+ SLAPD_CONF_LOCS="${ROOTDIR}etc/ldap ${ROOTDIR}etc/openldap ${ROOTDIR}usr/local/etc/openldap"
SLAPD_CONF_LOCATION=""
SLAPD_RUNNING=0
#
@@ -36,12 +36,12 @@
# Description : Check running OpenLDAP instance
Register --test-no LDAP-2219 --weight L --network NO --category security --description "Check running OpenLDAP instance"
if [ ${SKIPTEST} -eq 0 ]; then
- #YYY add additional slash
+ # TODO adding additional slash needed?
IsRunning slapd
if [ ${RUNNING} -eq 0 ]; then
Display --indent 2 --text "- Checking OpenLDAP instance" --result "${STATUS_NOT_FOUND}" --color WHITE
LogText "Result: No running slapd process found."
- else
+ else
Display --indent 2 --text "- Checking OpenLDAP instance" --result "${STATUS_FOUND}" --color GREEN
LogText "Result: Found running slapd process"
SLAPDFOUND=1
@@ -61,14 +61,14 @@
if [ -f ${I}/slapd.conf ]; then
LogText "Result: found ${I}/slapd.conf"
SLAPD_CONF_LOCATION="${I}/slapd.conf"
- else
+ else
LogText "Result: ${I} does not contain slapd.conf"
fi
done
# Check if we found a valid location
- if [ ! "${SLAPD_CONF_LOCATION}" = "" ]; then
+ if [ ! -z "${SLAPD_CONF_LOCATION}" ]; then
Display --indent 4 --text "- Checking slapd.conf" --result "${STATUS_FOUND}" --color GREEN
- else
+ else
Display --indent 4 --text "- Checking slapd.conf" --result "${STATUS_NOT_FOUND}" --color YELLOW
fi
fi