Skip to content

Record why the starlette advisories are pinned open - #10

Merged
kkdev92 merged 1 commit into
mainfrom
docs/starlette-advisory-note
Aug 17, 2026
Merged

Record why the starlette advisories are pinned open#10
kkdev92 merged 1 commit into
mainfrom
docs/starlette-advisory-note

Conversation

@kkdev92

@kkdev92 kkdev92 commented Aug 17, 2026

Copy link
Copy Markdown
Owner

Pinning CI's Python tools by hash made the resolved dependency set visible to
OpenSSF Scorecard's vulnerability scanner for the first time. It now reports
five published advisories against starlette 0.52.1, which PlatformIO pulls in:
PYSEC-2026-161, -248, -249, -2280 and -2281.

They are left open in code scanning rather than dismissed, because they are
real. What was missing is the reason they are still here, recorded where someone
reading the pin will find it.

Not reachable from anything CI runs

All five are flaws in serving HTTP — Host header validation, request path
handling, StaticFiles traversal, and form field limits — so each needs a
running Starlette server accepting requests.

PlatformIO lists starlette under the comment "PIO Home requirements" in
platformio/dependencies.py, and imports it in platformio/home/run.py, the
local web UI behind pio home. CI runs pio test, pio run and pio check;
none of them start that server. The only other reference,
platformio/compat.py, is a threadpool shim on the python_version < 3.9
branch, which CI's Python 3.12 never takes.

No version to move to

Every fix is in starlette 1.3.1 or earlier, but all are above 0.53. PlatformIO
6.1.19 — the current release — requires starlette >=0.19,<0.53, so no fixed
version is inside the range it accepts.

The exit condition is PlatformIO widening that constraint; regenerating the lock
then closes the alerts without anyone needing to remember this.

Note on scope

Only tools/requirements-ci.in changes, and only its comments. The generated
lock is byte-identical afterwards, which was checked by regenerating and
diffing.

🤖 Generated with Claude Code

Pinning CI's Python tools by hash made the resolved dependency set visible to
Scorecard's vulnerability scanner for the first time, and it reports five
published advisories against starlette 0.52.1, which PlatformIO pulls in.

They are left open in code scanning rather than dismissed, because they are
real. What was missing was the reason they are still here, written down where
someone looking at the pin will find it.

All five are flaws in serving HTTP: Host header validation, request path
handling, StaticFiles traversal, and form field limits. PlatformIO lists
starlette under "PIO Home requirements" and imports it only in
platformio/home/run.py, the web UI behind `pio home`. CI runs pio test, pio run
and pio check, none of which start that server; the only other reference, in
platformio/compat.py, sits on the Python < 3.9 branch that 3.12 never takes.

There is also nowhere to move to. Every fixed version is 1.3.1 or earlier but
above 0.53, and PlatformIO 6.1.19 -- the current release -- requires
starlette >=0.19,<0.53. The exit condition is PlatformIO widening that
constraint, after which regenerating the lock closes the alert.

The generated lock is byte-identical after this change; comments in the .in
file do not reach it.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@kkdev92
kkdev92 merged commit 3c3e6c8 into main Aug 17, 2026
13 checks passed
@kkdev92
kkdev92 deleted the docs/starlette-advisory-note branch August 17, 2026 14:09
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.

1 participant