Skip to content

Commit d7c0fc1

Browse files
feat: add SECURITY.md for documenting security policies and update tasks for branding and security model
1 parent 73c784c commit d7c0fc1

File tree

3 files changed

+59
-6
lines changed

3 files changed

+59
-6
lines changed

SECURITY.md

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
# Security Policy
2+
3+
We take the security of CPython Patch PR Action seriously. This document describes how we
4+
mitigate risk, how the action interacts with GitHub infrastructure, and how to report
5+
vulnerabilities responsibly.
6+
7+
## Supported versions
8+
9+
Only the latest released version (the `v0` tag during the pre-1.0 cycle) receives
10+
security updates. Please upgrade to the newest minor release before opening security
11+
reports.
12+
13+
## Required permissions
14+
15+
The action needs the following GitHub token permissions:
16+
17+
- `contents: write` – push branches with updated CPython versions.
18+
- `pull-requests: write` – create or update pull requests.
19+
20+
We recommend restricting the workflow token to the minimal scopes above. If you
21+
run the action in dry-run mode, you can downgrade permissions to `read` until you
22+
are ready to publish PRs.
23+
24+
## Network endpoints
25+
26+
External network access is limited to:
27+
28+
- `api.github.com` – fetch CPython tags and create/update pull requests.
29+
- `raw.githubusercontent.com/actions/python-versions` – retrieve runner manifests.
30+
- `www.python.org` – fallback source to confirm released patch versions.
31+
32+
No telemetry or analytics endpoints are used. If you need to run the action in a
33+
restricted environment, consider mirroring the above endpoints and pointing the
34+
workflow to your mirrors.
35+
36+
## Handling secrets
37+
38+
The action uses the workflow token (`GITHUB_TOKEN`) to push branches and open
39+
pull requests. Do not pass personal access tokens unless you need to target
40+
private forks or cross-organization repositories.
41+
42+
## Incident response
43+
44+
If we confirm a critical vulnerability, we will:
45+
46+
1. Publish a fixed release and update the `v0` tag.
47+
2. Document the risk, affected versions, and mitigation steps in the changelog.
48+
3. Notify followers through the repository Security Advisory system when available.
49+
50+
Thank you for helping keep the CPython ecosystem secure.

action.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,3 +38,6 @@ outputs:
3838
runs:
3939
using: node20
4040
main: dist/index.js
41+
branding:
42+
icon: python
43+
color: blue

docs/tasks.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -175,13 +175,13 @@ Use Context7 MCP for up to date documentation.
175175
Keep `CHANGELOG.md`. Plan `v0.x` then `v1`.
176176
Verify: Release notes generated on tag.
177177

178-
25. [ ] **Action icon and color**
179-
Update `action.yml` branding.
180-
Verify: Marketplace shows branding.
178+
25. [x] **Action icon and color**
179+
Update `action.yml` branding.
180+
Verify: Marketplace shows branding.
181181

182-
26. [ ] **Security model doc**
183-
Explain permissions, tokens, network endpoints.
184-
Verify: `SECURITY.md` updated.
182+
26. [x] **Security model doc**
183+
Explain permissions, tokens, network endpoints.
184+
Verify: `SECURITY.md` updated.
185185

186186
## 7) Testing matrix
187187

0 commit comments

Comments
 (0)