GHSA-3753-m2x2-q623

Suggest an improvement
Source
https://github.com/advisories/GHSA-3753-m2x2-q623
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/09/GHSA-3753-m2x2-q623/GHSA-3753-m2x2-q623.json
JSON Data
https://api.osv.dev/v1/vulns/GHSA-3753-m2x2-q623
Aliases
Published
2026-09-18T17:19:42Z
Modified
2026-09-18T17:30:10Z
Severity
  • 8.2 (High) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:L/A:N CVSS Calculator
Summary
File Viewer: DOM XSS via unsafe hyperlink schemes in the legacy DOC renderer
Details

Summary

Before 2.3.1, the legacy .doc renderer emitted document hyperlink targets after HTML escaping but without a URL-scheme allowlist. A crafted .doc could therefore render a live javascript:, vbscript:, data:, or similarly unsafe link. Script could execute in the embedding origin if a viewer clicked it.

Impact

Applications rendering untrusted legacy .doc files with @file-viewer/doc or the msdoc-viewer compatibility package could expose their origin to attacker-controlled script after link interaction.

Fix

Version 2.3.1 centralizes link handling, removes control-character and scheme confusion, blocks external document links by default, and in explicit allow mode accepts only HTTP(S), mail, telephone, safe relative URLs, and internal bookmarks. The renderer output is safe before mounting, with mount-boundary sanitization as defense in depth. The msdoc-viewer compatibility release containing the fix is 0.2.2.

Thanks to @shashank420 for responsibly reporting this issue.

Database specific
{
    "cwe_ids": [
        "CWE-79",
        "CWE-83"
    ],
    "github_reviewed": true,
    "github_reviewed_at": "2026-09-18T17:19:42Z",
    "nvd_published_at": null,
    "severity": "HIGH"
}
References

Affected packages

npm / @file-viewer/doc

Package

Name
@file-viewer/doc
View open source insights on deps.dev
Purl
pkg:npm/%40file-viewer/doc

Affected ranges

Type
SEMVER
Events
Introduced
0 Unknown introduced version / All previous versions are affected
Fixed
2.3.1

Database specific

last_known_affected_version_range
"<= 2.3.0"
source
"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/09/GHSA-3753-m2x2-q623/GHSA-3753-m2x2-q623.json"

npm / msdoc-viewer

Package

Affected ranges

Type
SEMVER
Events
Introduced
0 Unknown introduced version / All previous versions are affected
Fixed
0.2.2

Database specific

last_known_affected_version_range
"<= 0.2.1"
source
"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/09/GHSA-3753-m2x2-q623/GHSA-3753-m2x2-q623.json"