CVE-2022-40956
NixOS vulnerability analysis and mitigation

Overview

CVE-2022-40956 is a Content-Security-Policy (CSP) base-uri bypass vulnerability discovered in Mozilla Firefox. The vulnerability was identified on September 19, 2022, and affects Firefox ESR < 102.3, Thunderbird < 102.3, and Firefox < 105. When injecting an HTML base element, some requests would ignore the CSP's base-uri settings and accept the injected element's base instead, potentially leading to security policy bypasses (Mozilla Advisory, NVD).

Technical details

The vulnerability stems from a flaw in how Firefox handles HTML base elements during page loading. Specifically, the image preloader would accept the base tag without checking the CSP restrictions. The issue occurs when the CSP is delivered via both the Content-Security-Policy header and meta tag. The vulnerability has been assigned a CVSS v3.1 Base Score of 6.1 (Medium) with the vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N, indicating a network-exploitable vulnerability requiring user interaction (NVD).

Impact

The vulnerability allows attackers to bypass CSP base-uri restrictions, potentially leading to information leakage. This is particularly concerning for websites that use UUID-based user profiles with secret URLs, as it could enable attackers to leak paths that should be kept secret (Mozilla Bug).

Mitigation and workarounds

The vulnerability was fixed in Firefox 105, Firefox ESR 102.3, and Thunderbird 102.3. Users should upgrade to these versions or later to mitigate the risk. The fix involves proper implementation of CSP checks during the image preloading process (Mozilla Advisory, Mozilla Advisory ESR).

Additional resources


SourceThis report was generated using AI

Related NixOS vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2025-12819HIGH8.1
  • NixOSNixOS
  • pgbouncer
NoYesDec 03, 2025
CVE-2025-20777MEDIUM6.7
  • NixOSNixOS
  • android
NoNoDec 02, 2025
CVE-2025-65105MEDIUM5.3
  • NixOSNixOS
  • apptainer
NoYesDec 02, 2025
CVE-2025-20789MEDIUM4.4
  • NixOSNixOS
  • android
NoNoDec 02, 2025
CVE-2025-20788MEDIUM4.4
  • NixOSNixOS
  • android
NoNoDec 02, 2025

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management