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

fix xccdf_value substitution with dotnotation #12217

Merged
merged 2 commits into from
Aug 5, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ ocil_clause: '<tt>min-request-timeout</tt> is not set or is not set to an approp
ocil: |-
Run the following command:
<pre>$ oc get configmap config -n openshift-kube-apiserver -ojson | jq -r '.data["config.yaml"]' | jq '.apiServerArguments["min-request-timeout"]'</pre>
The output should return <pre> {{{ xccdf_value("var_api_min_request_timeout") }}} </pre>.
The output should return <pre> {{ .var_api_min_request_timeout }} </pre>.
sluetze marked this conversation as resolved.
Show resolved Hide resolved

warnings:
- general: |-
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ ocil_clause: 'OAuth server inactivity timeout is not configured'
ocil: |-
To check if the OAuth server timeout is configured, run the following command:
<pre>oc get oauth cluster -ojsonpath='{.spec.tokenConfig.accessTokenInactivityTimeout}'</pre>
the output should return <pre> {{{ xccdf_value("var_oauth_inactivity_timeout") }}} </pre>.
the output should return <pre> {{ .var_oauth_inactivity_timeout }} </pre>.
sluetze marked this conversation as resolved.
Show resolved Hide resolved

severity: medium

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ ocil_clause: 'event creation limits are not configured'
ocil: |-
Run the following command on the kubelet node(s):
<pre>$ for NODE_NAME in $(oc get nodes -ojsonpath='{.items[*].metadata.name}'); do oc get --raw /api/v1/nodes/$NODE_NAME/proxy/configz | jq '.kubeletconfig|.kind="KubeletConfiguration"|.apiVersion="kubelet.config.k8s.io/v1beta1"' | grep eventRecordQPS; done</pre>
The output should return <tt>{{{ xccdf_value("var_event_record_qps") }}}</tt>.
The output should return <tt>{{ .var_event_record_qps }}</tt>.

references:
cis@ocp4: 4.2.8
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ ocil_clause: 'the streaming connection timeouts are not disabled'
ocil: |-
Run the following command on the kubelet node(s):
<pre>$ sudo grep streamingConnectionIdleTimeout {{{ kubeletconf_path }}}</pre>
The output should return <tt>{{{ xccdf_value("var_streaming_connection_timeouts") }}}</tt>.
The output should return <tt>{{ .var_streaming_connection_timeouts }}</tt>.

references:
cis@eks: 3.2.5
Expand Down
Loading