CVE-2021-32661 TechDocs object element script injection

Medium 6.8 Published Updated

Attackers can inject malicious scripts via object elements in TechDocs, potentially stealing sensitive data from other users.

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

What is CVE-2021-32661?

CVE-2021-32661 is a medium-severity cross-site scripting vulnerability in backstage, published on 3 Jun 2021. An attacker needs administrator access to exploit it, and only if a user opens a file or follows a link.

Official description

Backstage is an open platform for building developer portals. In versions of Backstage's Techdocs Plugin (`@backstage/plugin-techdocs`) prior to 0.9.5, a malicious internal actor can potentially upload documentation content with malicious scripts by embedding the script within an `object` element. This may give access to sensitive data when other users visit that same documentation page. The ability to upload malicious content may be limited by internal code review processes, unless the chosen TechDocs deployment method is to use an object store and the actor has access to upload files directly to that store. The vulnerability is patched in the `0.9.5` release of `@backstage/plugin-techdocs`.

Weakness: CWE-434, CWE-77

Which versions are affected by CVE-2021-32661?

2 open source packages ship an affected version, including @backstage/plugin-techdocs. It affects 1 product.

PackageAffectedFixed in
@backstage/plugin-techdocs npmAll versions0.9.5
@backstage/plugin-techdocs npmAll versions0.9.5

Products include Linuxfoundation \@Backstage\/Plugin-Techdocs.

How do I fix CVE-2021-32661?

Upgrade @backstage/plugin-techdocs to 0.9.5 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-32661 being exploited?

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

Sources

Also known as GHSA-gg96-f8wr-p89f.

Is CVE-2021-32661 in your software?

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

Check your SBOMs for free