Skip to content

chore: Set permissions for GitHub actions#7257

Merged
headius merged 1 commit intojruby:masterfrom
turrisxyz:Pinned-Dependencies-GitHub
Aug 26, 2022
Merged

chore: Set permissions for GitHub actions#7257
headius merged 1 commit intojruby:masterfrom
turrisxyz:Pinned-Dependencies-GitHub

Conversation

@naveensrinivasan
Copy link
Contributor

 Restrict the GitHub token permissions only to the required ones; this way, even if the attackers will succeed in compromising your workflow, they won’t be able to do much.

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

https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions

https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs

[Keeping your GitHub Actions and workflows secure Part 1: Preventing pwn requests](https://securitylab.github.com/research/github-actions-preventing-pwn-requests/)

Signed-off-by: naveen <172697+naveensrinivasan@users.noreply.github.com>
@headius headius changed the base branch from master to jruby-9.3 August 26, 2022 16:46
@headius headius changed the base branch from jruby-9.3 to master August 26, 2022 16:46
@headius
Copy link
Member

headius commented Aug 26, 2022

I tried to rebase this on jruby-9.3 but it wanted to pull most of master along with it. Instead I'll apply the relevant change to the 9.3 branch by hand.

@headius headius added this to the JRuby 9.3.8.0 milestone Aug 26, 2022
@headius headius merged commit 3fa84e1 into jruby:master Aug 26, 2022
@headius
Copy link
Member

headius commented Aug 26, 2022

Thank you!

headius pushed a commit that referenced this pull request Aug 26, 2022
 Restrict the GitHub token permissions only to the required ones; this way, even if the attackers will succeed in compromising your workflow, they won’t be able to do much.

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

https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions

https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs

[Keeping your GitHub Actions and workflows secure Part 1: Preventing pwn requests](https://securitylab.github.com/research/github-actions-preventing-pwn-requests/)

Signed-off-by: naveen <172697+naveensrinivasan@users.noreply.github.com>

See #7257
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants