Re: RFR: 8293368: GitHub Workflows security hardening [v2]

2022-09-16 Thread Alex
On Wed, 7 Sep 2022 11:27:02 GMT, Alex  wrote:

>> This PR adds explicit [permissions 
>> section](https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions)
>>  to workflows. This is a security best practice because by default workflows 
>> run with [extended set of 
>> permissions](https://docs.github.com/en/actions/security-guides/automatic-token-authentication#permissions-for-the-github_token)
>>  (except from `on: pull_request` [from external 
>> forks](https://securitylab.github.com/research/github-actions-preventing-pwn-requests/)).
>>  By specifying any permission explicitly all others are set to none. By 
>> using the principle of least privilege the damage a compromised workflow can 
>> do (because of an 
>> [injection](https://securitylab.github.com/research/github-actions-untrusted-input/)
>>  or compromised third party tool or action) is restricted.
>> It is recommended to have [most strict permissions on the top 
>> level](https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions)
>>  and grant write permissions on [job 
>> level](https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs)
>>  case by case.
>
> Alex has updated the pull request with a new target base due to a merge or a 
> rebase. The incremental webrev excludes the unrelated changes brought in by 
> the merge/rebase. The pull request contains two additional commits since the 
> last revision:
> 
>  - Merge branch 'master' into patch-1
>  - Update submit.yml
>
>Signed-off-by: sashashura <93376818+sashash...@users.noreply.github.com>

Thanks, I missed that the ball in on my side.

-

PR: https://git.openjdk.org/jfx/pull/889


Re: RFR: 8293368: GitHub Workflows security hardening [v2]

2022-09-16 Thread Kevin Rushforth
On Mon, 5 Sep 2022 18:17:19 GMT, Alex  wrote:

>> @sashashura You need to enable running GHA workflows in your personal fork 
>> of the `jfx` repo. Given that you are changing the GHA workflow, we will 
>> need to see the results from your run in this PR.
>
>> @sashashura You need to enable running GHA workflows in your personal fork 
>> of the `jfx` repo. Given that you are changing the GHA workflow, we will 
>> need to see the results from your run in this PR.
> 
> https://github.com/sashashura/jfx/actions/runs/2995229526

@sashashura this is ready for you to `/integrate`

-

PR: https://git.openjdk.org/jfx/pull/889


Re: RFR: 8293368: GitHub Workflows security hardening [v2]

2022-09-12 Thread Ambarish Rapte
On Wed, 7 Sep 2022 11:27:02 GMT, Alex  wrote:

>> This PR adds explicit [permissions 
>> section](https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions)
>>  to workflows. This is a security best practice because by default workflows 
>> run with [extended set of 
>> permissions](https://docs.github.com/en/actions/security-guides/automatic-token-authentication#permissions-for-the-github_token)
>>  (except from `on: pull_request` [from external 
>> forks](https://securitylab.github.com/research/github-actions-preventing-pwn-requests/)).
>>  By specifying any permission explicitly all others are set to none. By 
>> using the principle of least privilege the damage a compromised workflow can 
>> do (because of an 
>> [injection](https://securitylab.github.com/research/github-actions-untrusted-input/)
>>  or compromised third party tool or action) is restricted.
>> It is recommended to have [most strict permissions on the top 
>> level](https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions)
>>  and grant write permissions on [job 
>> level](https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs)
>>  case by case.
>
> Alex has updated the pull request with a new target base due to a merge or a 
> rebase. The incremental webrev excludes the unrelated changes brought in by 
> the merge/rebase. The pull request contains two additional commits since the 
> last revision:
> 
>  - Merge branch 'master' into patch-1
>  - Update submit.yml
>
>Signed-off-by: sashashura <93376818+sashash...@users.noreply.github.com>

Marked as reviewed by arapte (Reviewer).

-

PR: https://git.openjdk.org/jfx/pull/889


Re: RFR: 8293368: GitHub Workflows security hardening [v2]

2022-09-07 Thread Kevin Rushforth
On Wed, 7 Sep 2022 11:27:02 GMT, Alex  wrote:

>> This PR adds explicit [permissions 
>> section](https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions)
>>  to workflows. This is a security best practice because by default workflows 
>> run with [extended set of 
>> permissions](https://docs.github.com/en/actions/security-guides/automatic-token-authentication#permissions-for-the-github_token)
>>  (except from `on: pull_request` [from external 
>> forks](https://securitylab.github.com/research/github-actions-preventing-pwn-requests/)).
>>  By specifying any permission explicitly all others are set to none. By 
>> using the principle of least privilege the damage a compromised workflow can 
>> do (because of an 
>> [injection](https://securitylab.github.com/research/github-actions-untrusted-input/)
>>  or compromised third party tool or action) is restricted.
>> It is recommended to have [most strict permissions on the top 
>> level](https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions)
>>  and grant write permissions on [job 
>> level](https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs)
>>  case by case.
>
> Alex has updated the pull request with a new target base due to a merge or a 
> rebase. The incremental webrev excludes the unrelated changes brought in by 
> the merge/rebase. The pull request contains two additional commits since the 
> last revision:
> 
>  - Merge branch 'master' into patch-1
>  - Update submit.yml
>
>Signed-off-by: sashashura <93376818+sashash...@users.noreply.github.com>

Looks good.

-

Marked as reviewed by kcr (Lead).

PR: https://git.openjdk.org/jfx/pull/889


Re: RFR: 8293368: GitHub Workflows security hardening [v2]

2022-09-07 Thread Alex
> This PR adds explicit [permissions 
> section](https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions)
>  to workflows. This is a security best practice because by default workflows 
> run with [extended set of 
> permissions](https://docs.github.com/en/actions/security-guides/automatic-token-authentication#permissions-for-the-github_token)
>  (except from `on: pull_request` [from external 
> forks](https://securitylab.github.com/research/github-actions-preventing-pwn-requests/)).
>  By specifying any permission explicitly all others are set to none. By using 
> the principle of least privilege the damage a compromised workflow can do 
> (because of an 
> [injection](https://securitylab.github.com/research/github-actions-untrusted-input/)
>  or compromised third party tool or action) is restricted.
> It is recommended to have [most strict permissions on the top 
> level](https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions)
>  and grant write permissions on [job 
> level](https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs)
>  case by case.

Alex has updated the pull request with a new target base due to a merge or a 
rebase. The incremental webrev excludes the unrelated changes brought in by the 
merge/rebase. The pull request contains two additional commits since the last 
revision:

 - Merge branch 'master' into patch-1
 - Update submit.yml
   
   Signed-off-by: sashashura <93376818+sashash...@users.noreply.github.com>

-

Changes:
  - all: https://git.openjdk.org/jfx/pull/889/files
  - new: https://git.openjdk.org/jfx/pull/889/files/ae6132c2..20840ce8

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jfx&pr=889&range=01
 - incr: https://webrevs.openjdk.org/?repo=jfx&pr=889&range=00-01

  Stats: 306 lines in 8 files changed: 295 ins; 4 del; 7 mod
  Patch: https://git.openjdk.org/jfx/pull/889.diff
  Fetch: git fetch https://git.openjdk.org/jfx pull/889/head:pull/889

PR: https://git.openjdk.org/jfx/pull/889