Skip to content

Commit

Permalink
fix GOSEC G601 issue (#324)
Browse files Browse the repository at this point in the history
  • Loading branch information
hirokuni-kitahara authored Mar 10, 2021
1 parent a603b2a commit 30c985e
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions integrity-shield-operator/resources/cr.go
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,12 @@ func BuildShieldConfigForIShield(cr *apiv1alpha1.IntegrityShield, scheme *runtim
}

for _, ir := range cr.Spec.IgnoreRules {
commonProfile.IgnoreRules = append(commonProfile.IgnoreRules, &ir)
tmpRule := ir
commonProfile.IgnoreRules = append(commonProfile.IgnoreRules, &tmpRule)
}
for _, ia := range cr.Spec.IgnoreAttrs {
commonProfile.IgnoreAttrs = append(commonProfile.IgnoreAttrs, &ia)
tmpAttr := ia
commonProfile.IgnoreAttrs = append(commonProfile.IgnoreAttrs, &tmpAttr)
}

ecc.Spec.ShieldConfig.CommonProfile = commonProfile
Expand Down

0 comments on commit 30c985e

Please sign in to comment.