From c7ad4c19d12881166bee337a078ddeda7c2f4bac Mon Sep 17 00:00:00 2001 From: Akis Maziotis Date: Fri, 26 Nov 2021 16:20:24 +0200 Subject: [PATCH] Add security scanning template --- workflow-templates/security.properties.json | 12 +++++++++++ workflow-templates/security.svg | 1 + workflow-templates/security.yml | 24 +++++++++++++++++++++ 3 files changed, 37 insertions(+) create mode 100644 workflow-templates/security.properties.json create mode 100644 workflow-templates/security.svg create mode 100644 workflow-templates/security.yml diff --git a/workflow-templates/security.properties.json b/workflow-templates/security.properties.json new file mode 100644 index 0000000..8d8bc92 --- /dev/null +++ b/workflow-templates/security.properties.json @@ -0,0 +1,12 @@ +{ + "name": "Security scanning", + "description": "Keeping Infrastructure as Code Secure. Static code analysis for DockerFiles, Helm Charts, and Terraform IAC.", + "iconName": "security", + "categories": [ + "Security", + "Scanning" + ], + "filePatterns": [ + ".*" + ] +} diff --git a/workflow-templates/security.svg b/workflow-templates/security.svg new file mode 100644 index 0000000..6550f47 --- /dev/null +++ b/workflow-templates/security.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/workflow-templates/security.yml b/workflow-templates/security.yml new file mode 100644 index 0000000..4df1f73 --- /dev/null +++ b/workflow-templates/security.yml @@ -0,0 +1,24 @@ +Name: Security scanning +on: + pull_request: +jobs: + security-scan: + runs-on: sre + name: security-checks + steps: + - name: Checkout repo + uses: actions/checkout@v2 + - name: Mkdir results-dir + run: mkdir -p results-dir + - name: Run Scan + uses: checkmarx/kics-action@v1.3 + with: + path: '.' + fail_on: high + output_path: results-dir + output_formats: 'json' + token: ${{ secrets.GITHUB_TOKEN }} + enable_comments: true + - name: Display Scan results + run: | + jq -e '.' results-dir/results.json