Skip to content

Commit

Permalink
Update test
Browse files Browse the repository at this point in the history
Bash variables whose names start with `$XCCDF_VALUE_` are valid
in SCE content. The `$XCCDF_VALUE_` variables are exported by `oscap`
so that the SCE check can use XCCDF Values in its code.
  • Loading branch information
jan-cerny committed Oct 30, 2024
1 parent 2ea5cd7 commit 03be6b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/test_xccdf_values_in_ds.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ if grep -iq "dangling reference to" "$DS" ; then
printf "Found dangling reference in %s, ensure correct usage of the xccdf_value Jinja macro!" "$DS" >&2
exit 1
fi
if grep -iq "xccdf_value" "$DS" ; then
if grep -iq "[^$]xccdf_value" "$DS" ; then
printf "Found obtrusive xccdf_value in %s, ensure correct usage of the xccdf_value Jinja macro!" "$DS" >&2
exit 1
fi
Expand Down

0 comments on commit 03be6b3

Please sign in to comment.