Advisory Database
  • Advisories
  • Dependency Scanning
  1. npm
  2. ›
  3. swagger-ui
  4. ›
  5. GMS-2016-45

GMS-2016-45: XSS in key names

July 21, 2016

Swagger-ui contains a cross site scripting (XSS) vulnerability in the key names for the following object path in the JSON document: .definitions.{USER_DEFINED}.properties.{INJECTABLE_KEY_NAME}. Supplying a key name with script tags causes arbitrary code execution. In addition it is possible to load the arbitrary JSON files remotely via the URL query-string parameter.

References

  • en.wikipedia.org/wiki/Content_Security_Policy
  • github.com/swagger-api/swagger-ui/issues/1865

Code Behaviors & Features

Detect and mitigate GMS-2016-45 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →

Affected versions

All versions before 2.2.1

Fixed versions

  • 2.2.2

Solution

Upgrade to version 2.2.2 or above.

Source file

npm/swagger-ui/GMS-2016-45.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Sun, 08 Nov 2026 00:16:25 +0000.