High firefox Logic Error 🔧 Commit mapped

Overview

High
Severity
CVSS
No
Exploited ITW
Fixed
Fix Status
Impacthigh
DescriptionIncorrect boundary conditions in the WebRTC: Audio/Video component
ComponentDOM
Bug ClassLogic Error
Tracker2001637
Fix commitc5b22051c757 (firefox) +9/-0
CISA KEVNot listed
CreditedIgor Morgenstern
Disclosed2026-02-24

Changed Functions

FunctionChangeNotes
if
dom/media/webrtc/libwebrtcglue/WebrtcGmpVideoCodec.cpp
modified

Files Changed

  • dom/media/webrtc/libwebrtcglue/WebrtcGmpVideoCodec.cpp
diff --git a/dom/media/webrtc/libwebrtcglue/WebrtcGmpVideoCodec.cpp b/dom/media/webrtc/libwebrtcglue/WebrtcGmpVideoCodec.cpp
index a2267af2dd1..a0967ebba0b 100644
--- a/dom/media/webrtc/libwebrtcglue/WebrtcGmpVideoCodec.cpp
+++ b/dom/media/webrtc/libwebrtcglue/WebrtcGmpVideoCodec.cpp
@@ -910,6 +910,15 @@ int32_t WebrtcGmpVideoDecoder::Decode(const webrtc::EncodedImage& aInputImage,
 }
 
 void WebrtcGmpVideoDecoder::Decode_g(UniquePtr<GMPDecodeData>&& aDecodeData) {
+  CheckedInt<uint32_t> dataSize(aDecodeData->mImage.size());
+  dataSize -= 4;
+  if (!dataSize.isValid()) {
+    GMP_LOG_ERROR("%s: bad input size (%zu)!", __PRETTY_FUNCTION__,
+                  aDecodeData->mImage.size());
+    mDecoderStatus = GMPInvalidArgErr;
+    return;
+  }
+
   if (!mGMP) {
     if (mInitting) {
       // InitDone hasn't been called yet (race)
Loading diff…