Add permissions to GitHub actions

- Included permissions for the action. https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions

Setting token permissions to read-only follows the principle of least privilege. This is important because attackers may use a compromised token with write access to push malicious code into the project.

https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions
This commit is contained in:
Naveen
2022-04-01 16:34:21 -05:00
committed by GitHub
parent 28ee975948
commit c743f13d0d

View File

@@ -6,6 +6,9 @@ on:
pull_request:
branches: [ master ]
permissions:
contents: read
jobs:
lint: