CVE-2023-22741 heap-over-flow in stun_parse_attribute in sofia-sip
- Published
- Updated
- Exploit status
- No public exploit known
- CISA SSVC
- Proof of concept public · automatable: yes · technical impact: total
- Technology
- UbuntuDebian
Description
Sofia-SIP is an open-source SIP User-Agent library, compliant with the IETF RFC3261 specification. In affected versions Sofia-SIP lacks both message length and attributes length checks when it handles STUN packets, leading to controllable heap-over-flow. For example, in stun_parse_attribute(), after we get the attribute's type and length value, the length will be used directly to copy from the heap, regardless of the message's left size. Since network users control the overflowed length, and the data is written to heap chunks later, attackers may achieve remote code execution by heap grooming or other exploitation methods. The bug was introduced 16 years ago in sofia-sip 1.12.4 (plus some patches through 12/21/2006) to in tree libs with git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3774 d0543943-73ff-0310-b7d9-9358b9ac24b2. Users are advised to upgrade. There are no known workarounds for this vulnerability.
Upgrade path
20 packages: 19 fixed.
| Package | Affected | Fixed in | Status |
|---|---|---|---|
| alpine/sofia-sip(Alpine v3.14) | < 1.13.11-r0 | 1.13.11-r0 | Fixed |
| alpine/sofia-sip(Alpine v3.15) | < 1.13.11-r0 | 1.13.11-r0 | Fixed |
| alpine/sofia-sip(Alpine v3.16) | < 1.13.11-r0 | 1.13.11-r0 | Fixed |
| alpine/sofia-sip(Alpine v3.17) | < 1.13.11-r0 | 1.13.11-r0 | Fixed |
| alpine/sofia-sip(Alpine v3.18) | < 1.13.11-r0 | 1.13.11-r0 | Fixed |
| alpine/sofia-sip(Alpine v3.19) | < 1.13.11-r0 | 1.13.11-r0 | Fixed |
| alpine/sofia-sip(Alpine v3.20) | < 1.13.11-r0 | 1.13.11-r0 | Fixed |
| alpine/sofia-sip(Alpine v3.21) | < 1.13.11-r0 | 1.13.11-r0 | Fixed |
| alpine/sofia-sip(Alpine v3.22) | < 1.13.11-r0 | 1.13.11-r0 | Fixed |
| alpine/sofia-sip(Alpine v3.23) | < 1.13.11-r0 | 1.13.11-r0 | Fixed |
| alpine/sofia-sip(Alpine v3.24) | < 1.13.11-r0 | 1.13.11-r0 | Fixed |
| debian/sofia-sip(Debian 12) | < 1.12.11+20110422.1+1e14eea~dfsg-4 | 1.12.11+20110422.1+1e14eea~dfsg-4 | Fixed |
| debian/sofia-sip(Debian 13) | < 1.12.11+20110422.1+1e14eea~dfsg-4 | 1.12.11+20110422.1+1e14eea~dfsg-4 | Fixed |
| debian/sofia-sip(Debian 14) | < 1.12.11+20110422.1+1e14eea~dfsg-4 | 1.12.11+20110422.1+1e14eea~dfsg-4 | Fixed |
| signalwire sofia-sip | < 1.13.11 | 1.13.11 | Fixed |
| ubuntu/sofia-sip(Ubuntu 18.04) | < 1.12.11+20110422.1-2.1+deb10u3build0.18.04.1; = 1.12.11+20110422.1-2.1; = 1.12.11+20110422.1-2.1build1 | 1.12.11+20110422.1-2.1+deb10u3build0.18.04.1 | Fixed |
| ubuntu/sofia-sip(Ubuntu 20.04) | < 1.12.11+20110422.1-2.1+deb10u3ubuntu0.20.04.1; = 1.12.11+20110422.1-2.1build1 | 1.12.11+20110422.1-2.1+deb10u3ubuntu0.20.04.1 | Fixed |
| ubuntu/sofia-sip(Ubuntu 22.04) | < 1.12.11+20110422.1-2.1+deb10u3ubuntu0.22.04.1; = 1.12.11+20110422.1-2.1ubuntu1; = 1.12.11+20110422.1-2.1ubuntu2 | 1.12.11+20110422.1-2.1+deb10u3ubuntu0.22.04.1 | Fixed |
| ubuntu/sofia-sip(Ubuntu Pro 16.04) | < 1.12.11+20110422.1-2.1+deb10u3ubuntu0.16.04.1~esm1; = 1.12.11+20110422.1-2ubuntu1 | 1.12.11+20110422.1-2.1+deb10u3ubuntu0.16.04.1~esm1 | Fixed |
| freeswitch/sofia-sip | = < 1.13.11 | No fix listed | Versions listed |
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| debian/sofia-sip(Debian:12) | < 1.12.11+20110422.1+1e14eea~dfsg-4 | 1.12.11+20110422.1+1e14eea~dfsg-4 |
| debian/sofia-sip(Debian:13) | < 1.12.11+20110422.1+1e14eea~dfsg-4 | 1.12.11+20110422.1+1e14eea~dfsg-4 |
| debian/sofia-sip(Debian:14) | < 1.12.11+20110422.1+1e14eea~dfsg-4 | 1.12.11+20110422.1+1e14eea~dfsg-4 |
| freeswitch/sofia-sip | = < 1.13.11 | No fix listed |
| ubuntu/sofia-sip(Ubuntu:22.04) | < 1.12.11+20110422.1-2.1+deb10u3ubuntu0.22.04.1 | 1.12.11+20110422.1-2.1+deb10u3ubuntu0.22.04.1 |
| signalwire sofia-sip | < 1.13.11 | 1.13.11 |
| alpine/sofia-sip(Alpine:v3.14) | < 1.13.11-r0 | 1.13.11-r0 |
| alpine/sofia-sip(Alpine:v3.15) | < 1.13.11-r0 | 1.13.11-r0 |
| alpine/sofia-sip(Alpine:v3.16) | < 1.13.11-r0 | 1.13.11-r0 |
| alpine/sofia-sip(Alpine:v3.17) | < 1.13.11-r0 | 1.13.11-r0 |
| alpine/sofia-sip(Alpine:v3.18) | < 1.13.11-r0 | 1.13.11-r0 |
| alpine/sofia-sip(Alpine:v3.19) | < 1.13.11-r0 | 1.13.11-r0 |
| alpine/sofia-sip(Alpine:v3.20) | < 1.13.11-r0 | 1.13.11-r0 |
| alpine/sofia-sip(Alpine:v3.21) | < 1.13.11-r0 | 1.13.11-r0 |
| alpine/sofia-sip(Alpine:v3.22) | < 1.13.11-r0 | 1.13.11-r0 |
| alpine/sofia-sip(Alpine:v3.23) | < 1.13.11-r0 | 1.13.11-r0 |
| alpine/sofia-sip(Alpine:v3.24) | < 1.13.11-r0 | 1.13.11-r0 |
| ubuntu/sofia-sip(Ubuntu:Pro:16.04) | < 1.12.11+20110422.1-2.1+deb10u3ubuntu0.16.04.1~esm1 | 1.12.11+20110422.1-2.1+deb10u3ubuntu0.16.04.1~esm1 |
| ubuntu/sofia-sip(Ubuntu:Pro:16.04) | = 1.12.11+20110422.1-2ubuntu1 | No fix listed |
| ubuntu/sofia-sip(Ubuntu:18.04) | < 1.12.11+20110422.1-2.1+deb10u3build0.18.04.1 | 1.12.11+20110422.1-2.1+deb10u3build0.18.04.1 |
| ubuntu/sofia-sip(Ubuntu:18.04) | = 1.12.11+20110422.1-2.1 | No fix listed |
| ubuntu/sofia-sip(Ubuntu:18.04) | = 1.12.11+20110422.1-2.1build1 | No fix listed |
| ubuntu/sofia-sip(Ubuntu:20.04) | < 1.12.11+20110422.1-2.1+deb10u3ubuntu0.20.04.1 | 1.12.11+20110422.1-2.1+deb10u3ubuntu0.20.04.1 |
| ubuntu/sofia-sip(Ubuntu:20.04) | = 1.12.11+20110422.1-2.1build1 | No fix listed |
| ubuntu/sofia-sip(Ubuntu:22.04) | = 1.12.11+20110422.1-2.1ubuntu1 | No fix listed |
Show 1 more
| Product | Affected versions | Fixed in |
|---|---|---|
| ubuntu/sofia-sip(Ubuntu:22.04) | = 1.12.11+20110422.1-2.1ubuntu2 | No fix listed |
References
- Debian Security Tracker CVE-2023-22741 vendor-advisory
- https://github.com/freeswitch/sofia-sip/security/advisories/GHSA-8599-x7rq-fr54 exploit issue-tracking patch third-party-advisory
- https://github.com/freeswitch/sofia-sip/commit/da53e4fbcb138b080a75576dd49c1fff2ada2764 patch third-party-advisory
- www.debian.org
- Ubuntu CVE tracker issue-tracking vendor-advisory
- USN-5932-1 vendor-advisory
- www.cve.org issue-tracking
- security.alpinelinux.org vendor-advisory
- bugs.debian.org issue-tracking