CVE-2022-28284
High · 8.8CVSS
8.8
EPSS
0.6%
Published
Dec 22, 2022
CISA due date
—
Cloudanix analysis
A browser flaw allowed certain web page graphics to secretly run harmful code, letting attackers steal information or take over user sessions when people visited malicious sites.
- Exploitation
- Requires User Interaction
- Attacker needs
- User Interaction
- Complexity
- Low
- Impact
- Full Compromise
- Component
- Application
- Class
- XSS
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
The SVG <use> element in Gecko-based browsers could load unexpected external content that executes script in the context of the embedding page, bypassing expected script security boundaries relied upon by web developers.
Why it matters to the business
Attackers can execute arbitrary code inside a user's browser session, enabling theft of credentials, session hijacking, or unauthorized actions on web applications visited by affected users; the high prevalence of Firefox deployments increases organizational exposure until patches are applied.
How an attack unfolds
An attacker hosts or injects a malicious web page containing a crafted SVG document that uses the <use> element to reference external content; when a victim loads the page in an unpatched Firefox version, the unexpected content executes script, achieving cross-site scripting without requiring user interaction beyond visiting the page.
How to fix it
Upgrade all instances of Mozilla Firefox to version 99 or later. Where immediate upgrades are not possible, enforce strict Content-Security-Policy headers that disallow inline scripts and restrict external resource loading on internal web applications.
How to confirm the fix worked
Confirm Firefox version 99 or newer is installed across the fleet; test affected web applications with a proof-of-concept SVG <use> payload in a lab environment to verify script execution is blocked; review browser release notes for the alignment change.
Typical attack path
- Attacker crafts malicious SVG referencing unexpected content via the <use> element
- Attacker delivers the SVG through a compromised or attacker-controlled website
- Victim visits the page using vulnerable Firefox < 99
- Browser loads and executes the injected script in the page origin
- Attacker gains control over the victim's browsing context for data exfiltration or further attacks
How to detect it
Review web proxy or browser telemetry logs for access to pages containing unusual SVG <use> references; examine endpoint process execution for Firefox instances loading unexpected external resources; check for post-exploitation artifacts such as unauthorized script activity in browser developer tools or security logs.
What your security team should do
- Prioritize patching Firefox fleet-wide within the next 30 days given the public disclosure and potential for easy exploitation via web content
- Deploy or strengthen Content-Security-Policy on all internal and customer-facing web applications to mitigate similar client-side script injection risks
- Monitor browser telemetry and update compliance dashboards for continued presence of versions below 99
- Educate web developers on testing cross-browser SVG behavior during security reviews
The record
SVG's <code><use></code> element could have been used to load unexpected content that could have executed script in certain circumstances. While the specification seems to allow this, other browsers do not, and web developers relied on this property for script security so gecko's implementation was aligned with theirs. This vulnerability affects Firefox < 99.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Ubuntu:18.04:LTS | firefox | 0 | 99.0+build2-0ubuntu0.18.04.2 |
| Ubuntu:20.04:LTS | firefox | 0 | 99.0+build2-0ubuntu0.20.04.2 |
| Ubuntu:22.04:LTS | firefox | 0 | 1:1snap1-0ubuntu1 |
| openSUSE:Tumbleweed | MozillaFirefox | 0 | 99.0-1.1 |
| openSUSE:Tumbleweed | firefox-esr | 0 | 128.5.1-1.1 |
Related vulnerabilities
- CVE-2023-25736 An invalid downcast from `nsHTMLDocument` to `nsIContent` could have lead to undefined… Also affects firefox
- CVE-2023-25733 The return value from `gfx::SourceSurfaceSkia::Map()` wasn't being verified which could… Also affects firefox
- CVE-2023-32210 Documents were incorrectly assuming an ordering of principal objects when ensuring we… Also affects firefox
- CVE-2023-32216 Memory safety bugs present in Firefox 112. Also affects firefox
- CVE-2023-32209 A maliciously crafted favicon could have led to an out of memory crash. Also affects firefox
- CVE-2023-32208 Service workers could reveal script base URL due to dynamic `import()`. Also affects firefox
- CVE-2023-29551 Memory safety bugs present in Firefox 111. Also affects firefox
- CVE-2023-32207 A missing delay in popup notifications could have made it possible for an attacker to… Also affects firefox