Skip to content

Commit e0a74b0

Browse files
authored
Release v1.0.0 (#9)
1 parent fa42160 commit e0a74b0

File tree

9 files changed

+5754
-9936
lines changed

9 files changed

+5754
-9936
lines changed

.github/workflows/test.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,9 @@ jobs:
2121
- uses: actions/checkout@v3
2222
- uses: ./
2323
with:
24-
milliseconds: 1000
24+
sarifFile: test-data/webgoat.sarif
25+
- name: Archive SARIF output
26+
uses: actions/upload-artifact@v3
27+
with:
28+
name: sarif-output
29+
path: test-data/webgoat.sarif

README.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,22 @@ Compare a CodeQL SARIF results file to a security standard CWE list and annotate
55
## Usage in GitHub Actions
66

77
```
8+
- name: Perform CodeQL Analysis
9+
uses: github/codeql-action/analyze@v2
10+
with:
11+
category: "/language:${{matrix.language}}"
12+
upload: false
13+
output: sarif-results
14+
815
- name: Annotate CodeQL SARIF with OWASP Top 10 2021 tag
916
uses: ctcampbell/codeql-sarif-security-standard-annotator@v1
17+
with:
18+
sarifFile: sarif-results/${{matrix.language}}.sarif
19+
20+
- name: Upload SARIF
21+
uses: github/codeql-action/upload-sarif@v2
22+
with:
23+
sarif_file: sarif-results/${{matrix.language}}.sarif
1024
```
1125

1226
```
@@ -25,5 +39,4 @@ inputs:
2539
outputFile:
2640
required: false
2741
description: 'The output SARIF file path, defaults to the input SARIF file path'
28-
default: '${{ inputs.sarifFile }}'
2942
```

action.yml

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,23 +7,14 @@ inputs:
77
description: 'The CodeQL SARIF result file'
88
cweFile:
99
required: false
10-
description: 'The CWE list XML file'
11-
default: '${{ github.action_path }}/security-standards/owasp-top10-2021.xml'
10+
description: 'The CWE list XML file, defaults to OWASP Top 10 2021'
1211
securityStandardTag:
1312
required: false
1413
description: 'The security standard tag to add to the SARIF file'
1514
default: 'owasp-top10-2021'
1615
outputFile:
1716
required: false
1817
description: 'The output SARIF file path, defaults to the input SARIF file path'
19-
default: '${{ inputs.sarifFile }}'
2018
runs:
21-
using: 'composite'
22-
steps:
23-
- run: |
24-
node '${{ github.action_path }}/dist/index.js' \
25-
--sarifFile '${{ inputs.sarifFile }}' \
26-
--cweFile '${{ inputs.cweFile }}' \
27-
--securityStandardTag '${{ inputs.securityStandardTag }}' \
28-
--outputFile '${{ inputs.outputFile }}'
29-
shell: bash
19+
using: 'node16'
20+
main: 'dist/index.js'

0 commit comments

Comments
 (0)