Vulnerabilities > CVE-2023-49786 - Race Condition vulnerability in multiple products
Summary
Asterisk is an open source private branch exchange and telephony toolkit. In Asterisk prior to versions 18.20.1, 20.5.1, and 21.0.1; as well as certified-asterisk prior to 18.9-cert6; Asterisk is susceptible to a DoS due to a race condition in the hello handshake phase of the DTLS protocol when handling DTLS-SRTP for media setup. This attack can be done continuously, thus denying new DTLS-SRTP encrypted calls during the attack. Abuse of this vulnerability may lead to a massive Denial of Service on vulnerable Asterisk servers for calls that rely on DTLS-SRTP. Commit d7d7764cb07c8a1872804321302ef93bf62cba05 contains a fix, which is part of versions 18.20.1, 20.5.1, 21.0.1, amd 18.9-cert6.
Vulnerable Configurations
Common Weakness Enumeration (CWE)
Common Attack Pattern Enumeration and Classification (CAPEC)
- Leveraging Race Conditions This attack targets a race condition occurring when multiple processes access and manipulate the same resource concurrently and the outcome of the execution depends on the particular order in which the access takes place. The attacker can leverage a race condition by "running the race", modifying the resource and modifying the normal execution flow. For instance a race condition can occur while accessing a file, the attacker can trick the system by replacing the original file with his version and cause the system to read the malicious file.
- Leveraging Time-of-Check and Time-of-Use (TOCTOU) Race Conditions This attack targets a race condition occurring between the time of check (state) for a resource and the time of use of a resource. The typical example is the file access. The attacker can leverage a file access race condition by "running the race", meaning that he would modify the resource between the first time the target program accesses the file and the time the target program uses the file. During that period of time, the attacker could do something such as replace the file and cause an escalation of privilege.
References
- http://packetstormsecurity.com/files/176251/Asterisk-20.1.0-Denial-Of-Service.html
- http://packetstormsecurity.com/files/176251/Asterisk-20.1.0-Denial-Of-Service.html
- http://seclists.org/fulldisclosure/2023/Dec/24
- http://seclists.org/fulldisclosure/2023/Dec/24
- http://www.openwall.com/lists/oss-security/2023/12/15/7
- http://www.openwall.com/lists/oss-security/2023/12/15/7
- https://github.com/asterisk/asterisk/commit/d7d7764cb07c8a1872804321302ef93bf62cba05
- https://github.com/asterisk/asterisk/commit/d7d7764cb07c8a1872804321302ef93bf62cba05
- https://github.com/asterisk/asterisk/security/advisories/GHSA-hxj9-xwr8-w8pq
- https://github.com/asterisk/asterisk/security/advisories/GHSA-hxj9-xwr8-w8pq
- https://github.com/EnableSecurity/advisories/tree/master/ES2023-01-asterisk-dtls-hello-race
- https://github.com/EnableSecurity/advisories/tree/master/ES2023-01-asterisk-dtls-hello-race
- https://lists.debian.org/debian-lts-announce/2023/12/msg00019.html
- https://lists.debian.org/debian-lts-announce/2023/12/msg00019.html