diff --git a/ADconnection.sh b/ADconnection.sh index b86b2d1..7334fe9 100755 --- a/ADconnection.sh +++ b/ADconnection.sh @@ -1151,7 +1151,7 @@ read -r DOMAIN else echo "" fi -therealm=$( realm discover | grep -i realm-name | awk '{print $2}') +therealm=$( realm discover | grep -i configured | awk '{print $2}') if [ "$therealm" = "no" ] then echo Realm configured?.. "${RED_TEXT}FAIL${END}" @@ -1161,7 +1161,7 @@ fi if [ -f /etc/sudoers.d/admins ] < /dev/null > /dev/null 2>&1 then echo Checking sudoers file.. "${INTRO_TEXT}OK${END}" -grouPs=$(grep -i "$myhost" /etc/sudoers.d/admins | cut -d '%' -f2 | cut -d '=' -f1 | sed -e 's/\//g') +grouPs=$(grep -i "$myhost" /etc/sudoers.d/sudoers | cut -d '%' -f2 | cut -d '=' -f1 | sed -e 's/\//g') if [ $grouPs = "$myhost""sudoers" ] then echo Checking sudoers users.. "${INTRO_TEXT}OK${END}"