High firefox Integer Overflow 🔧 Commit mapped

Overview

High
Severity
—
CVSS
No
Exploited ITW
Fixed
Fix Status
Impacthigh
DescriptionSandbox escape due to incorrect boundary conditions, integer overflow in the XPCOM component
ComponentCore
Bug ClassInteger Overflow
Tracker2016374
Fix commitcb251d78965a (firefox) +8/-0
CISA KEVNot listed
CreditedSajeeb Lohani
Disclosed2026-03-24

Changed Functions

FunctionChangeNotes
if
xpcom/io/SlicedInputStream.cpp
modified

Files Changed

  • xpcom/io/SlicedInputStream.cpp
diff --git a/xpcom/io/SlicedInputStream.cpp b/xpcom/io/SlicedInputStream.cpp
index c64af8e9dd8..185990a08de 100644
--- a/xpcom/io/SlicedInputStream.cpp
+++ b/xpcom/io/SlicedInputStream.cpp
@@ -491,6 +491,14 @@ bool SlicedInputStream::Deserialize(
 
   const SlicedInputStreamParams& params = aParams.get_SlicedInputStreamParams();
 
+  auto end = CheckedUint64(params.start()) + params.length();
+  if (!end.isValid()) {
+    return false;
+  }
+  if (params.curPos() > end.value()) {
+    return false;
+  }
+
   nsCOMPtr<nsIInputStream> stream =
       InputStreamHelper::DeserializeInputStream(params.stream());
   if (!stream) {
Loading diff…