## NLTK: WekaClassifier passes an unvalidated caller-controlled model path to the weka JVM, bypassing nltk.pathsec containment

- 種別: advisory
- 重大度: high
- 関連技術: python
- 公開日時: 2026-10-27T14:50:30.000Z
- 情報源: GitHub Advisory Database (https://github.com/advisories/GHSA-j456-xh4h-cpf2)
- パーマリンク: https://vulnpulse.app/items/ghsa-ghsa-j456-xh4h-cpf2

影響: pip:nltk <= 3.10.3 → 3.10.4
WekaClassifier in NLTK passes a caller-controlled model file path to the weka Java VM without any nltk.pathsec validation. WekaClassifier.train puts the caller's model_filename verbatim into the weka argv ["-d", model_filename, ...] (weka writes the trained model there), and WekaClassifier._classify_many puts self._model into ["-l", self._model, ...] (weka reads it). Under nltk.pathsec.ENFORCE=True (the default on current HEAD), NLTK's stated invariant — established by advisory CVE-2026-81726 /…