Server-side Request Forgery (SSRF) Affecting swagger-ui-dist package, versions <4.1.3
Threat Intelligence
Do your applications use this vulnerable package?
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 applications- Snyk ID SNYK-JS-SWAGGERUIDIST-6056393
- published 10 Dec 2021
- disclosed 9 Dec 2021
- credit Unknown
Introduced: 9 Dec 2021
CVE-2021-46708 Open this link in a new tabHow to fix?
Upgrade swagger-ui-dist
to version 4.1.3 or higher.
Overview
swagger-ui-dist is a module that exposes Swagger-UI's entire dist folder as a dependency-free npm module. Use swagger-ui instead, if you'd like to have npm install dependencies for you.
Affected versions of this package are vulnerable to Server-side Request Forgery (SSRF) via the ?url
parameter, which was intended to allow displaying remote OpenAPI definitions. This functionality may pose a risk for users who host their own SwaggerUI instances. In particular, including remote OpenAPI definitions opens a vector for phishing attacks by abusing the trusted names/domains of self-hosted instances.
NOTE: This vulnerability has also been identified as: CVE-2018-25031