Public exploit available
Public proof-of-concept or exploit code exists (ExploitDB / Metasploit / Nuclei).

CVE-2024-22207Initialization of a Resource with an Insecure Default in Fastify-swagger-ui

Severity
5.3MEDIUMNVD
EPSS
14.4%
top 5.57%
CISA KEV
Not in KEV
Exploit
PoC available
Public exploit / PoC exists
Timeline
PublishedJan 15
Latest updateJan 16

Description

fastify-swagger-ui is a Fastify plugin for serving Swagger UI. Prior to 2.1.0, the default configuration of `@fastify/swagger-ui` without `baseDir` set will lead to all files in the module's directory being exposed via http routes served by the module. The vulnerability is fixed in v2.1.0. Setting the `baseDir` option can also work around this vulnerability.

CVSS vector

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:NExploitability: 3.9 | Impact: 1.4

Affected Packages3 packages

npmfastify/swagger-ui2.0.02.1.0
CVEListV5fastify/fastify-swagger-ui< 2.1.0
NVDsmartbear/swagger_ui2.0.02.1.0

Patches

🔴Vulnerability Details

3
GHSA
Default swagger-ui configuration exposes all files in the module2024-01-16
OSV
Default swagger-ui configuration exposes all files in the module2024-01-16
CVEList
Default swagger-ui configuration exposes all files in the module2024-01-15

💥Exploits & PoCs

1
Nuclei
Fastify Swagger-UI - Information Disclosure
CVE-2024-22207 — Fastify-swagger-ui vulnerability | cvebase