Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added CRYP-7932 to determine if the system has enabled macOS FileVault. #1458

Merged
merged 2 commits into from
May 14, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions include/tests_crypto
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,33 @@
fi
#
#################################################################################
#
# Test : CRYP-7932
# Description : Determine if system has enabled macOS FileVault encryption
Register --test-no CRYP-7932 --os macOS --weight L --network NO --category crypto --description "Determine if system has enabled macOS FileVault encryption"
if [ ${SKIPTEST} -eq 0 ]; then
if command -v fdesetup &> /dev/null; then
case $(fdesetup status) in
*"FileVault is On."*)
LogText "Result: FileVault is enabled."
Display --indent 2 --text "- FileVault is enabled." --result "${STATUS_OK}" --color GREEN
Report "encryption[]=filevault"
AddHP 3 3
;;
*)
LogText "Result: FileVault is not enabled."
Display --indent 2 --text "- FileVault is not enabled." --result "${STATUS_WARNING}" --color RED
AddHP 0 3
;;
esac
else
LogText "Result: fdesetup command not found. Unable to determine FileVault status."
Display --indent 2 --text "- Unable to determine FileVault status (fdesetup command not found)." --result "${STATUS_WARNING}" --color YELLOW
AddHP 0 3
fi
fi
#
#################################################################################
#
# Test : CRYP-8002
# Description : Gather available kernel entropy
Expand Down