CVE-2021-39391 Cross-site Scripting in Beego

Medium 6.1 Published Updated

Attackers can inject malicious scripts via URI paths in the Beego admin panel, potentially compromising administrator sessions.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
A user has to click or open something
Fix
Available

What is CVE-2021-39391?

CVE-2021-39391 is a medium-severity cross-site scripting vulnerability in n/a, published on 14 Sep 2021. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.

Official description

Cross Site Scripting (XSS) vulnerability exists in the admin panel in Beego v2.0.1 via the URI path in an HTTP request, which is activated by administrators viewing the "Request Statistics" page.

Weakness: CWE-79

Which versions are affected by CVE-2021-39391?

2 open source packages ship an affected version, including github.com/beego/beego/v2. It affects 1 product.

PackageAffectedFixed in
github.com/beego/beego/v2 GoAll versions2.0.2
github.com/beego/beego/v2 GoAll versions2.0.2

Products include Beego Beego.

How do I fix CVE-2021-39391?

Upgrade github.com/beego/beego/v2 to 2.0.2 or later.

Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.

Is CVE-2021-39391 being exploited?

There is no known exploitation of CVE-2021-39391 in the wild and no public exploit code.

Sources

Also known as GHSA-c77f-4rgj-jfr4.

Is CVE-2021-39391 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free