Skip to content

Commit 7260be8

Browse files
fix: rename misleading trueVar variable to allowPrivilegeEscalation
The variable `trueVar` was set to `false` and used for `AllowPrivilegeEscalation`, making the name confusing and misleading. Rename it to `allowPrivilegeEscalation` to accurately reflect its purpose and value. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: Chai Bot <chai-bot@redhat.com>
1 parent 35f8816 commit 7260be8

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎controllers/scc.go‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import (
88

99
func GetScc() *secv1.SecurityContextConstraints {
1010

11-
trueVar := false
11+
allowPrivilegeEscalation := false
1212
sccName := "sandboxed-containers-operator-scc"
1313

1414
return &secv1.SecurityContextConstraints{
@@ -24,7 +24,7 @@ func GetScc() *secv1.SecurityContextConstraints {
2424
AllowHostNetwork: false,
2525
AllowHostPID: false,
2626
AllowHostPorts: false,
27-
AllowPrivilegeEscalation: &trueVar,
27+
AllowPrivilegeEscalation: &allowPrivilegeEscalation,
2828
AllowPrivilegedContainer: false,
2929
RequiredDropCapabilities: []corev1.Capability{"MKNOD", "FSETID", "KILL", "FOWNER"},
3030
AllowedCapabilities: []corev1.Capability{"DAC_READ_OVERRIDE"},

0 commit comments

Comments
 (0)