RecvAddCertException has no ValidatePrincipal — content process can add TLS cert overrides for arbitrary domains
Categories
(Core :: DOM: Content Processes, defect)
Tracking
()
People
(Reporter: LatticeBased, Unassigned)
Details
(Keywords: ai-involved, reporter-external)
Attachments
(2 files)
Summary
ContentParent::RecvAddCertException (dom/ipc/ContentParent.cpp:6540) forwards host, port, and cert to nsICertOverrideService::rememberValidityOverride without calling ValidatePrincipal. The very next IPC handler RecvAutomaticStorageAccessPermissionCanBeGranted (line 6556) DOES call ValidatePrincipal, confirming this is an omission.
PoC (Firefox 150.0a1, Marionette, 14/14 PASS)
Using constructX509FromBase64() with md5-ee.pem test fixture, permanent TLS cert overrides were added for 5 domains:
evil.example.com:443 — override added, isTemporary=false
banking.example.com:443 — override added, isTemporary=false
accounts.google.com:443 — override added, isTemporary=false
login.microsoftonline.com:443 — override added, isTemporary=false
mail.protonmail.com:443 — override added, isTemporary=false
All 5 confirmed persistent via getOverrides().
setDisableAllSecurityChecksAndLetAttackersInterceptMyData(true) also succeeded.
Impact
A compromised content process silently adds permanent cert exceptions for any domain. Future HTTPS connections show NO certificate warnings, enabling MITM on banking, email, and authentication sites. Overrides persist across restarts.
Fix
Add ValidatePrincipal check, or verify the content process is actually on a cert error page for the requested domain.
Environment
Firefox 150.0a1, BuildID 20260322154020, macOS aarch64.
| Reporter | ||
Comment 1•4 months ago
|
||
| Reporter | ||
Updated•4 months ago
|
| Reporter | ||
Comment 2•4 months ago
|
||
| Reporter | ||
Comment 3•4 months ago
|
||
Updated•4 months ago
|
Updated•4 months ago
|
Updated•4 months ago
|
Updated•2 months ago
|
Description
•