Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Working through adding what is needed to do #239.
This pull request makes the following changes:
It relates to the following issue #s:
cc @bhamail / @DarthHater
How im testing this?
Currently using the https://github.com/sonatype-nexus-community/intentionally-vulnerable-golang-project project. And running my local build against nancy with the
-o sarif
output option and then dumping to a file and doing some magic incantations necessary for github to be happy. (the action will take care of this later)And then this curl command to send the results to my forked repo above
If you want to stitch the above together to check it out on your own repo you should be able to by changing the url in the curl above.
So whats it look like??
So you can poke around here.
https://github.com/zendern/intentionally-vulnerable-golang-project/security/code-scanning?query=tool%3Anancy
List screen
Github alert types can only be of one of the 4 types. [none, note, warning and error]. I have implemented it as follows :
Following the lead here
nancy/internal/audit/auditlogtextformatter.go
Lines 124 to 135 in 30fb76a
Outstanding question on this would be should Low == Note as far as github code scanning goes or does Warning still make sense to use??
Vulnerability details page
Looks wise we can probably maybe do better. Markdown support is available in some fields but does have the caveat of once you throw a newline in there Github collapses it and will make you expand before you get them sweet sweet details.
Also something to note since we do not have full (is transitive deps/actually in go.mod/Gopkg.lock file) I am just pinning the line number of the issue to the first line in the corresponding go.mod/Gopkg.lock file to indicate its a dependency issue. Does this seem reasonable??
What's left outstanding?