-
Notifications
You must be signed in to change notification settings - Fork 184
Conversation
f58c195
to
5f2d8eb
Compare
c6dd9a0
to
dd892ec
Compare
653c2d6
to
c0f0bfa
Compare
d62d289
to
366d31b
Compare
82baa84
to
744b2df
Compare
744b2df
to
edae749
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! +1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, but I'd appreciate a peek from someone with more experience in this codebase (@genevieveluyt). All concerns are in test code.
I wish there was an automated way to know that we set the new Auditor
field on every *kubeaudit.AuditResult
.
The Name
->Rule
rename is handy for bringing every *AuditResult
declaration into this diff. I'm not going to pull this into an IDE and check every reference because I think reviewing the PR gives pretty good coverage.
e62d544
to
2ba56a8
Compare
cfb8a79
to
36ffd3b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is really cool!
My main concern for the Name
-> Rule
switch was that it would be a runtime breaking change for the CLI but it's not! The CLI is unaffected and if folks upgrade the package as a dependency, it will fail during compile-time. The Rule
+ Auditor
fields are an improvement in my eyes 👍
Other than that I mainly wondered about the choice of flags and the rest are nits.
Really nice that you introduced a sarif
package to contain all that logic. Very clean and organized implementation 👏
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some minor things but logic looks good!
Do we still need https://github.com/Shopify/kubeaudit/blob/ds/adds-support-for-sarif-output/internal/sarif/rules.go#L37?
Co-authored-by: Genevieve Luyt <[email protected]>
Not really. Removed it here |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 LGTM Nice work! :-)
Closes #436
Left some comments/questions for reviewers as part of self-review
go run cmd/main.go -f internal/sarif/fixtures/apparmor-invalid.yaml all --format="sarif" > kubeaudit.sarif
will yield a new sarif report (kubeaudit.sarif):Examples of the sarif output being used with Github Code Scanning. SARIF uploaded with a Github action that _thepwagner set up in a private repo:
Type of change
Name
toRule
, users of the library will need to update the code when they bump the versionHow Has This Been Tested?
go run cmd/main.go -f internal/sarif/fixtures/apparmor-invalid.yaml all -s kubeaudit.sarif
will yield a new sarif report (kubeaudit.sarif
) as well as print the results on the terminalChecklist: