-
Notifications
You must be signed in to change notification settings - Fork 6.5k
chore(security.txt): make compliant by adding an Expires field
#9005
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,55 @@ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| # Refreshes apps/site/public/.well-known/security.txt so its RFC 9116 Expires | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| # field never silently lapses. Runs once a year and opens a PR bumping Expires | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| # ~13 months out — a human must confirm the contact/policy are still valid | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| # before merging. The generous window (>1yr) means the file never expires even | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| # if a run is delayed, and anchoring to the fixed yearly run avoids drift. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+1
to
+5
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| name: Refresh security.txt Expires | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| on: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| workflow_dispatch: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| schedule: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - cron: '0 8 1 1 *' # once a year, Jan 1 at 08:00 UTC | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| permissions: {} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| jobs: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| refresh-expires: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| runs-on: ubuntu-latest | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| if: github.repository_owner == 'nodejs' | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| permissions: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| contents: write | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| pull-requests: write | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| steps: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - name: Checkout | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Run |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| persist-credentials: false | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - name: Bump Expires (~13 months out) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| env: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| SECURITY_TXT: apps/site/public/.well-known/security.txt | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| run: | | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| set -euo pipefail | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| new=$(date -u -d '+400 days' +%Y-%m-%dT23:59:59.000Z) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yearly refresh leaves thin expiry bufferMedium Severity The yearly cron plus a human-merge PR only leaves about 35 days of headroom in steady state ( Reviewed by Cursor Bugbot for commit e2a51ca. Configure here. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Expires bump exceeds RFC one-year limitLow Severity The refresh sets Reviewed by Cursor Bugbot for commit e2a51ca. Configure here. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| sed -i "s/^Expires:.*/Expires: ${new}/I" "$SECURITY_TXT" | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Expires bump drifts each cycleLow Severity The bump sets Additional Locations (1)Reviewed by Cursor Bugbot for commit 0679b62. Configure here.
Comment on lines
+28
to
+34
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As Cursor said, we should bump the in-place year, not re-calculate a date, e.g. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - name: Create Pull Request (only if the date changed) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
Conformity with our other workflows. No need to add the |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| uses: gr2m/create-or-update-pull-request-action@b65137ca591da0b9f43bad7b24df13050ea45d1b # v1.10.1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| env: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| commit-message: 'chore: refresh security.txt Expires' | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| title: 'chore: refresh security.txt Expires' | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| body: | | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Annual refresh of the `Expires` field in `apps/site/public/.well-known/security.txt` so it | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| never silently lapses. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| **Before merging, please confirm the rest of the file is still accurate:** | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - The `Contact` (HackerOne) is still the correct, actively-monitored channel | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - The linked `Policy` is still the intended vulnerability-disclosure path | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| If anything has changed, update it in this PR before extending the expiration. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| cc: @nodejs/security-wg | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| labels: security | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| branch: automated/security-txt-expiry | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+41
to
+55
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
For conformity |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,2 +1,3 @@ | ||
| Contact: https://hackerone.com/nodejs | ||
| Expires: 2027-06-30T23:59:59.000Z | ||
| Policy: https://github.com/nodejs/node/security/policy#security |


There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's call this
bump-security-txt-expiry.ymlso it's clear this bumps it