CVE-2021-39391: Cross-site Scripting in Beego
6.1
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.47398%
CWE
Published
9/15/2021
Updated
12/7/2023
KEV Status
No
Technology
Go
Technical Details
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
github.com/beego/beego/v2 | go | < 2.0.2 | 2.0.2 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability manifests in the request statistics display functionality of the admin panel. The URI path from HTTP requests is stored and later rendered unescaped in HTML templates. The controller method responsible for handling the 'Request Statistics' page view (likely in logs.go
) would pass the raw URI to templates without adequate output encoding. This matches the XSS pattern described where URI input becomes executable script content when viewed by admins. The confidence is high as this is the standard pattern for Beego admin controllers and the vulnerability description explicitly implicates URI path handling in statistics display.