Skip to content

Commit 799b508

Browse files
[StepSecurity] Apply security best practices (#328)
Signed-off-by: StepSecurity Bot <bot@stepsecurity.io> Co-authored-by: stepsecurity-app[bot] <188008098+stepsecurity-app[bot]@users.noreply.github.com>
1 parent b2d34d6 commit 799b508

9 files changed

Lines changed: 22 additions & 14 deletions

File tree

.github/workflows/ast-scan.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ on:
1010

1111
jobs:
1212
cx-scan:
13-
runs-on: ubuntu-latest
13+
runs-on: cx-public-ubuntu-x64
1414
steps:
1515
- name: Checkout
16-
uses: actions/checkout@v4
16+
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
1717
- name: Checkmarx One CLI Action
1818
uses: checkmarx/ast-github-action@6c56658230f79c227a55120e9b24845d574d5225 #main
1919
with:

.github/workflows/auto-merge-pr.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ permissions:
66

77
jobs:
88
dependabot-merge:
9-
runs-on: ubuntu-latest
9+
runs-on: cx-public-ubuntu-x64
1010
if: contains(github.head_ref, 'feature/update_cli')
1111
steps:
1212
- name: Enable auto-merge for Dependabot PRs

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
contents: write
1212
steps:
1313
- name: Fetch Sources
14-
uses: actions/checkout@v4
14+
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
1515

1616
- name: Setup VSTest
1717
uses: darenm/Setup-VSTest@3a16d909a1f3bbc65b52f8270d475d905e7d3e44 #v1
@@ -22,7 +22,7 @@ jobs:
2222
vs-version: '17.2'
2323

2424
- name: Install .NET 6.0 Windows Desktop Runtime
25-
uses: actions/setup-dotnet@v4
25+
uses: actions/setup-dotnet@67a3573c9a986a3f9c594539f4ab511d57bb3ce9 # v4.3.1
2626
with:
2727
dotnet-version: '6.0.x'
2828
include-prerelease: false

.github/workflows/dependabot-auto-merge.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ permissions:
66

77
jobs:
88
dependabot-merge:
9-
runs-on: ubuntu-latest
9+
runs-on: cx-public-ubuntu-x64
1010
if: ${{ github.actor == 'dependabot[bot]' }}
1111
steps:
1212
- name: Dependabot metadata

.github/workflows/manual-tag.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,17 @@ on:
77
description: 'Next release tag'
88
required: true
99

10+
permissions:
11+
contents: read
12+
1013
jobs:
1114
tag-creation:
12-
runs-on: ubuntu-latest
15+
permissions:
16+
contents: write # for Git to git push
17+
runs-on: cx-public-ubuntu-x64
1318
steps:
1419
- name: Checkout
15-
uses: actions/checkout@v4
20+
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
1621
with:
1722
token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
1823
- name: Tag

.github/workflows/nightly.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
name: Check if dependabot commits exist
1616
outputs:
1717
isDependabot: ${{ steps.check-dependabot.outputs.dependabotExists }}
18-
runs-on: ubuntu-latest
18+
runs-on: cx-public-ubuntu-x64
1919
steps:
2020
- name: Check if dependabot commits exist
2121
id: check-dependabot
@@ -24,7 +24,7 @@ jobs:
2424
run: echo "dependabotExists=$(echo $GITHUB_CONTEXT | jq '.event.commits[0].author | any(. == "dependabot[bot]")')" >> $GITHUB_OUTPUT
2525

2626
delete-tag:
27-
runs-on: ubuntu-latest
27+
runs-on: cx-public-ubuntu-x64
2828
needs: check-dependabot-commits
2929
if: ${{needs.check-dependabot-commits.outputs.isDependabot == 'false'}}
3030
steps:

.github/workflows/pr-label.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
pr-labeler:
1111
permissions:
1212
pull-requests: write # for TimonVS/pr-labeler-action to add labels in PR
13-
runs-on: ubuntu-latest
13+
runs-on: cx-public-ubuntu-x64
1414
steps:
1515
- uses: TimonVS/pr-labeler-action@f9c084306ce8b3f488a8f3ee1ccedc6da131d1af #v5
1616
with:

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ jobs:
3939
CLI_VERSION: ${{ steps.extract_cli_version.outputs.CLI_VERSION }}
4040
steps:
4141
- name: Fetch Sources
42-
uses: actions/checkout@v4
42+
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
4343
with:
4444
token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
4545

.github/workflows/update-cli.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,14 @@ on:
55
repository_dispatch:
66
types: [cli-version-update]
77

8+
permissions:
9+
contents: read
10+
811
jobs:
912
update-checkmarx-cli:
10-
runs-on: ubuntu-latest
13+
runs-on: cx-public-ubuntu-x64
1114
steps:
12-
- uses: actions/checkout@v4
15+
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
1316
- name: Get Latest Checkmarx API version
1417
id: checkmarx-ast-cli
1518
run: |

0 commit comments

Comments
 (0)