CVE-2021-4185

HIGH7.5/ 10.0
Share:
Published: December 30, 2021 at 10:15 PM
Modified: November 3, 2025 at 10:15 PM
Source: cve@gitlab.com

Vulnerability Description

Infinite loop in the RTMPT dissector in Wireshark 3.6.0 and 3.4.0 to 3.4.10 allows denial of service via packet injection or crafted capture file

CVSS Metrics

Base Score
7.5
Severity
HIGH
Vector String
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Weaknesses (CWE)

Source: nvd@nist.gov

AI Security Analysis

01 // Technical Summary

Wireshark, a widely used network protocol analyzer, is vulnerable to a denial-of-service (DoS) attack due to an infinite loop within its RTMPT dissector. Attackers can exploit this flaw by injecting specially crafted network packets or providing a malicious capture file, causing Wireshark to consume excessive resources and become unresponsive, effectively disrupting network analysis and potentially impacting security operations.

02 // Vulnerability Mechanism

Step 1: Payload Delivery: The attacker crafts a malicious RTMPT packet or creates a capture file (.pcap or .pcapng) containing a malicious RTMPT packet.

Step 2: Packet Injection/File Opening: The attacker either injects the crafted packet onto a network monitored by Wireshark or provides the malicious capture file to a user or system running Wireshark.

Step 3: Dissector Trigger: Wireshark's RTMPT dissector processes the malicious packet or the packet within the capture file.

Step 4: Infinite Loop: Due to a logic flaw in the dissector, the crafted packet triggers an infinite loop within the parsing logic.

Step 5: Resource Exhaustion: The infinite loop consumes CPU resources, leading to high CPU utilization and potentially system instability.

Step 6: Denial of Service: Wireshark becomes unresponsive, preventing network analysis and potentially disrupting security operations.

03 // Deep Technical Analysis

The vulnerability stems from an infinite loop within the RTMPT (Real Time Messaging Protocol Tunneling) dissector in Wireshark. The dissector, responsible for parsing and interpreting RTMPT traffic, contains a logic error that allows a crafted packet or capture file to trigger an endless loop. This loop likely occurs during the processing of specific RTMPT message types or malformed data within the packet. The root cause is likely a failure to properly handle edge cases or unexpected data formats within the RTMPT protocol, leading to a condition where the parsing logic repeatedly executes without advancing, consuming CPU resources and preventing the program from progressing. The infinite loop prevents the program from exiting or processing other packets, leading to a DoS condition.

References & Intelligence

https://gitlab.com/gitlab-org/cves/-/blob/master/2021/CVE-2021-4185.json
Source: cve@gitlab.com
Third Party Advisory
https://gitlab.com/wireshark/wireshark/-/issues/17745
Source: cve@gitlab.com
ExploitIssue TrackingThird Party Advisory
https://lists.debian.org/debian-lts-announce/2022/03/msg00041.html
Source: cve@gitlab.com
Mailing ListThird Party Advisory
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/Q6XGBKWSQFCVYUN4ZK3O3NJIFP3OAFVT/
Source: cve@gitlab.com
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/R5AEK3XTOIOGCGUILUFISMGX54YJXWGJ/
Source: cve@gitlab.com
https://security.gentoo.org/glsa/202210-04
Source: cve@gitlab.com
Third Party Advisory
https://www.oracle.com/security-alerts/cpuapr2022.html
Source: cve@gitlab.com
Third Party Advisory
https://www.wireshark.org/security/wnpa-sec-2021-17.html
Source: cve@gitlab.com
Vendor Advisory
https://gitlab.com/gitlab-org/cves/-/blob/master/2021/CVE-2021-4185.json
Source: af854a3a-2127-422b-91ae-364da2661108
Third Party Advisory
https://gitlab.com/wireshark/wireshark/-/issues/17745
Source: af854a3a-2127-422b-91ae-364da2661108
ExploitIssue TrackingThird Party Advisory
https://lists.debian.org/debian-lts-announce/2022/03/msg00041.html
Source: af854a3a-2127-422b-91ae-364da2661108
Mailing ListThird Party Advisory
https://lists.debian.org/debian-lts-announce/2024/09/msg00049.html
Source: af854a3a-2127-422b-91ae-364da2661108
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/Q6XGBKWSQFCVYUN4ZK3O3NJIFP3OAFVT/
Source: af854a3a-2127-422b-91ae-364da2661108
https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/R5AEK3XTOIOGCGUILUFISMGX54YJXWGJ/
Source: af854a3a-2127-422b-91ae-364da2661108
https://security.gentoo.org/glsa/202210-04
Source: af854a3a-2127-422b-91ae-364da2661108
Third Party Advisory
https://www.oracle.com/security-alerts/cpuapr2022.html
Source: af854a3a-2127-422b-91ae-364da2661108
Third Party Advisory
https://www.wireshark.org/security/wnpa-sec-2021-17.html
Source: af854a3a-2127-422b-91ae-364da2661108
Vendor Advisory
CVE-2021-4185 - HIGH Severity (7.5) | Free CVE Database | 4nuxd