Skip to content

NanoHTTPD Cross-site Scripting vulnerability

Moderate severity GitHub Reviewed Published Feb 25, 2021 to the GitHub Advisory Database • Updated Sep 12, 2023

Package

maven org.nanohttpd:nanohttpd-nanolets (Maven)

Affected versions

<= 2.3.1

Patched versions

None

Description

An issue was discovered in RouterNanoHTTPD.java in NanoHTTPD through 2.3.1. The GeneralHandler class implements a basic GET handler that prints debug information as an HTML page. Any web server that extends this class without implementing its own GET handler is vulnerable to reflected XSS, because the GeneralHandler GET handler prints user input passed through the query string without any sanitization.

References

Published by the National Vulnerability Database Feb 23, 2021
Reviewed Feb 24, 2021
Published to the GitHub Advisory Database Feb 25, 2021
Last updated Sep 12, 2023

Severity

Moderate

EPSS score

Exploit Prediction Scoring System (EPSS)

This score estimates the probability of this vulnerability being exploited within the next 30 days. Data provided by FIRST.
(44th percentile)

Weaknesses

Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. Learn more on MITRE.

CVE ID

CVE-2020-13697

GHSA ID

GHSA-pr5m-4w22-8483

Source code

Loading Checking history
See something to contribute? Suggest improvements for this vulnerability.