test: fix apparmor detection
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
This commit is contained in:
parent
79073df3c2
commit
15f23bc6ac
2 changed files with 8 additions and 12 deletions
|
@ -161,12 +161,10 @@ function is_seccomp_enabled() {
|
|||
out=$(cat "$BOOT_CONFIG_FILE_PATH" | grep CONFIG_SECCOMP=)
|
||||
if [[ "$out" =~ "CONFIG_SECCOMP=y" ]]; then
|
||||
echo 1
|
||||
else
|
||||
echo 0
|
||||
return
|
||||
fi
|
||||
else
|
||||
echo 0
|
||||
fi
|
||||
echo 0
|
||||
}
|
||||
|
||||
function is_apparmor_enabled() {
|
||||
|
@ -174,10 +172,8 @@ function is_apparmor_enabled() {
|
|||
out=$(cat "$APPARMOR_PARAMETERS_FILE_PATH")
|
||||
if [[ "$out" =~ "Y" ]]; then
|
||||
echo 1
|
||||
else
|
||||
echo 0
|
||||
return
|
||||
fi
|
||||
else
|
||||
echo 0
|
||||
fi
|
||||
echo 0
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue