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 applicationsLearn about Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') vulnerabilities in an interactive lesson.
Start learningUpgrade aiohttp
to version 3.9.2 or higher.
Affected versions of this package are vulnerable to Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') via the configuration of static routes when the follow_symlinks
option is set to True
. An attacker can read arbitrary files on the system by exploiting the lack of validation for file paths to ensure they are within the specified root directory for static files.
Notes:
This vulnerability has been present since the introduction of the follow_symlinks
parameter.
An application is only vulnerable with setup code like:
app.router.add_routes([
web.static("/static", "static/", follow_symlinks=True), # Remove follow_symlinks to avoid the vulnerability
])
This vulnerability can be mitigated by disabling the follow_symlinks
option if it is set to True
, especially in environments beyond restricted local development. Additionally, using a reverse proxy server to handle static resources is recommended over serving static resources directly with aiohttp
in production environments.