Skip to content

security: risk-accept nltk PYSEC-2026-597 (unreachable code path)#485

Merged
cgfixit merged 1 commit into
mainfrom
claude/cyclaw-optimize-nltk-cve-accept
Jul 9, 2026
Merged

security: risk-accept nltk PYSEC-2026-597 (unreachable code path)#485
cgfixit merged 1 commit into
mainfrom
claude/cyclaw-optimize-nltk-cve-accept

Conversation

@cgfixit

@cgfixit cgfixit commented Jul 9, 2026

Copy link
Copy Markdown
Owner

What

Adds PYSEC-2026-597 to pip-audit.yml's --ignore-vuln list, alongside the existing CVE-2026-45829 (chromadb) entry, with a written justification comment in the same format/rigor.

Why / benefit

pip-audit's scan job has been failing on every open PR since this CVE surfaced against nltk==3.9.4 — confirmed pre-existing and unrelated to any PR's own diff (identical failure reproduces on a clean checkout of main).

Investigated before proposing this, rather than reflexively ignore-listing:

  • No patched release exists. Checked PyPI directly: 3.9.4 is the current latest nltk release. There is nothing to bump to.
  • The vulnerable code path is unreachable here. CyClaw's only nltk usage, repo-wide, is from nltk.stem import PorterStemmer (retrieval/stemmer.py) — grepped to confirm. It never calls nltk.download() or nltk.data.load(). The nltk vulnerability classes on record (downloader zip-slip RCE, punkt/corpus-reader path traversal) all live in code this repo never executes. stemmer.py's own header comment already made this exact reachability argument for the punkt tokenizer specifically — this PR just extends the same already-established reasoning to the newly-surfaced CVE and gives it a formal, auditable entry instead of leaving scan red with no explanation.

Risk to monitor

Re-evaluate when nltk ships a patched release — the comment says so explicitly, matching the chromadb entry's "re-evaluate on bump" convention. If CyClaw's nltk usage ever expands beyond PorterStemmer (e.g. adopting punkt or the downloader), this risk acceptance no longer holds and should be revisited immediately.

Verify

yaml.safe_load confirms the file still parses. Trial-merged against the currently-open #481 (which also touches pip-audit.yml, in the unrelated verify-install job) — 0 conflicts, both edits coexist cleanly.

Scan context

Follow-up from a CyClaw-Optimize session; not one of the original 8 scan findings — raised by pip-audit's own CI output surfacing during that session's PR reviews.


Generated by Claude Code

pip-audit's scan job has been failing on every PR since this CVE surfaced --
confirmed pre-existing (identical on main, unrelated to any PR's own diff).
No patched nltk release exists yet (3.9.4 is current latest on PyPI).
CyClaw's only nltk usage is PorterStemmer (retrieval/stemmer.py); it never
calls nltk.download()/nltk.data.load(), so the known nltk vulnerability
classes (downloader zip-slip RCE, punkt/corpus-reader path traversal) live
in code this repo never executes -- stemmer.py's own header comment already
documented this exact reachability argument for the punkt CVE specifically.
Mirrors the existing chromadb CVE-2026-45829 risk-acceptance entry's format
and rigor.
@cgfixit cgfixit marked this pull request as ready for review July 9, 2026 19:39
@cgfixit cgfixit merged commit 21baebd into main Jul 9, 2026
32 checks passed
@cgfixit cgfixit deleted the claude/cyclaw-optimize-nltk-cve-accept branch July 9, 2026 19:40
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