Snyk has a proof-of-concept or detailed explanation of how to exploit this vulnerability.
The probability is the direct output of the EPSS model, and conveys an overall sense of the threat of exploitation in the wild. The percentile measures the EPSS probability relative to all known EPSS scores. Note: This data is updated daily, relying on the latest available EPSS model version. Check out the EPSS documentation for more details.
In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.
Test your applicationsUpgrade nltk to version 3.10.4 or higher.
nltk is a Natural Language Toolkit (NLTK) is a Python package for natural language processing.
Affected versions of this package are vulnerable to Uncontrolled Search Path Element via Prover9Parent.config_prover9(binary_location=...) (and Mace, which inherits it) accepting a relative binary_location and passing it as path_to_bin to find_binary, which disables the CWD-relative rejection guard in internals.py. A truthy path_to_bin sets searching_bare_name to False, so the guard if searching_bare_name and not os.path.isabs(path): continue never executes, allowing a relative path such as ./prover9 to be stored in self._prover9_bin. On the next prove() call, _call passes that relative path to subprocess.Popen, executing the attacker-planted binary from the current working directory as the invoking user.
Note: This is only exploitable when the application is configured with a relative binary_location and the attacker can write to the resolved directory.
In a directory containing an executable ./prover9:
from nltk.inference.prover9 import Prover9
p = Prover9(); p.config_prover9(binary_location='.')
# p._prover9_bin == './prover9'; subsequent prove() Popens it from CWD
Runtime-confirmed: find_binary('prover9', path_to_bin='.') → './prover9'; bare find_binary('prover9') and relative PROVER9='.' via default _find_binary both raise LookupError (the default path is protected).