CVE-2022-24754: CWE-120: Buffer Copy without Checking Size of Input ('Classic Buffer Overflow') in pjsip pjproject
PJSIP is a free and open source multimedia communication library written in C language. In versions prior to and including 2.12 PJSIP there is a stack-buffer overflow vulnerability which only impacts PJSIP users who accept hashed digest credentials (credentials with data_type `PJSIP_CRED_DATA_DIGEST`). This issue has been patched in the master branch of the PJSIP repository and will be included with the next release. Users unable to upgrade need to check that the hashed digest data length must be equal to `PJSIP_MD5STRLEN` before passing to PJSIP.
AI Analysis
Technical Summary
CVE-2022-24754 is a medium-severity stack-based buffer overflow vulnerability identified in the open-source multimedia communication library PJSIP, specifically within the pjproject component. PJSIP is widely used for SIP (Session Initiation Protocol) signaling and multimedia communication in VoIP applications. The vulnerability affects versions up to and including 2.12 of pjproject. It arises from improper handling of hashed digest credentials (data_type `PJSIP_CRED_DATA_DIGEST`) during authentication processes. Specifically, the code does not verify that the length of the hashed digest data matches the expected constant `PJSIP_MD5STRLEN` before copying it onto the stack, leading to a classic buffer overflow (CWE-120). This unchecked copy can overwrite adjacent memory on the stack, potentially allowing an attacker to execute arbitrary code, cause a denial of service, or crash the application. The vulnerability is triggered only when PJSIP is configured to accept hashed digest credentials, which is common in SIP authentication scenarios. The issue has been patched in the master branch of the PJSIP repository, but users who cannot upgrade immediately are advised to implement manual length checks to ensure the hashed digest data length equals `PJSIP_MD5STRLEN` before processing. There are no known exploits in the wild as of the published date, and no official CVSS score has been assigned. However, the vulnerability's nature and context suggest a significant risk if exploited, especially in environments where PJSIP is exposed to untrusted networks or users.
Potential Impact
For European organizations, the impact of this vulnerability can be considerable, particularly for those relying on PJSIP-based VoIP infrastructure, unified communications, or multimedia communication platforms. Exploitation could lead to remote code execution or denial of service, disrupting critical communication services. This can affect enterprises, telecom providers, government agencies, and any sector dependent on SIP-based communication. Confidentiality could be compromised if attackers gain control over the system, potentially intercepting or manipulating voice communications. Integrity and availability are also at risk due to possible application crashes or unauthorized code execution. Given the widespread use of PJSIP in various telephony and communication products, the scope of affected systems is broad. The vulnerability requires no authentication but does require the attacker to send specially crafted SIP messages containing malicious hashed digest credentials, which is feasible in exposed or poorly segmented networks. This elevates the risk in environments with public-facing SIP endpoints or inadequate network controls. The absence of known exploits suggests limited active targeting currently, but the potential impact warrants proactive mitigation.
Mitigation Recommendations
1. Upgrade to the latest version of pjproject where the vulnerability is patched as soon as possible. 2. For environments where immediate upgrade is not feasible, implement strict input validation by verifying that the length of the hashed digest credential data equals `PJSIP_MD5STRLEN` before processing. 3. Employ network segmentation and restrict access to SIP services to trusted networks and users only, minimizing exposure to untrusted sources. 4. Deploy SIP-aware intrusion detection and prevention systems (IDS/IPS) to monitor and block malformed or suspicious SIP authentication attempts. 5. Regularly audit and monitor logs for unusual authentication failures or malformed SIP messages that could indicate exploitation attempts. 6. Apply principle of least privilege to the systems running PJSIP to limit the impact of potential exploitation. 7. Educate network and security teams about this specific vulnerability to ensure rapid detection and response if exploitation attempts occur.
Affected Countries
Germany, France, United Kingdom, Italy, Spain, Netherlands, Poland, Sweden, Belgium, Austria
CVE-2022-24754: CWE-120: Buffer Copy without Checking Size of Input ('Classic Buffer Overflow') in pjsip pjproject
Description
PJSIP is a free and open source multimedia communication library written in C language. In versions prior to and including 2.12 PJSIP there is a stack-buffer overflow vulnerability which only impacts PJSIP users who accept hashed digest credentials (credentials with data_type `PJSIP_CRED_DATA_DIGEST`). This issue has been patched in the master branch of the PJSIP repository and will be included with the next release. Users unable to upgrade need to check that the hashed digest data length must be equal to `PJSIP_MD5STRLEN` before passing to PJSIP.
AI-Powered Analysis
Technical Analysis
CVE-2022-24754 is a medium-severity stack-based buffer overflow vulnerability identified in the open-source multimedia communication library PJSIP, specifically within the pjproject component. PJSIP is widely used for SIP (Session Initiation Protocol) signaling and multimedia communication in VoIP applications. The vulnerability affects versions up to and including 2.12 of pjproject. It arises from improper handling of hashed digest credentials (data_type `PJSIP_CRED_DATA_DIGEST`) during authentication processes. Specifically, the code does not verify that the length of the hashed digest data matches the expected constant `PJSIP_MD5STRLEN` before copying it onto the stack, leading to a classic buffer overflow (CWE-120). This unchecked copy can overwrite adjacent memory on the stack, potentially allowing an attacker to execute arbitrary code, cause a denial of service, or crash the application. The vulnerability is triggered only when PJSIP is configured to accept hashed digest credentials, which is common in SIP authentication scenarios. The issue has been patched in the master branch of the PJSIP repository, but users who cannot upgrade immediately are advised to implement manual length checks to ensure the hashed digest data length equals `PJSIP_MD5STRLEN` before processing. There are no known exploits in the wild as of the published date, and no official CVSS score has been assigned. However, the vulnerability's nature and context suggest a significant risk if exploited, especially in environments where PJSIP is exposed to untrusted networks or users.
Potential Impact
For European organizations, the impact of this vulnerability can be considerable, particularly for those relying on PJSIP-based VoIP infrastructure, unified communications, or multimedia communication platforms. Exploitation could lead to remote code execution or denial of service, disrupting critical communication services. This can affect enterprises, telecom providers, government agencies, and any sector dependent on SIP-based communication. Confidentiality could be compromised if attackers gain control over the system, potentially intercepting or manipulating voice communications. Integrity and availability are also at risk due to possible application crashes or unauthorized code execution. Given the widespread use of PJSIP in various telephony and communication products, the scope of affected systems is broad. The vulnerability requires no authentication but does require the attacker to send specially crafted SIP messages containing malicious hashed digest credentials, which is feasible in exposed or poorly segmented networks. This elevates the risk in environments with public-facing SIP endpoints or inadequate network controls. The absence of known exploits suggests limited active targeting currently, but the potential impact warrants proactive mitigation.
Mitigation Recommendations
1. Upgrade to the latest version of pjproject where the vulnerability is patched as soon as possible. 2. For environments where immediate upgrade is not feasible, implement strict input validation by verifying that the length of the hashed digest credential data equals `PJSIP_MD5STRLEN` before processing. 3. Employ network segmentation and restrict access to SIP services to trusted networks and users only, minimizing exposure to untrusted sources. 4. Deploy SIP-aware intrusion detection and prevention systems (IDS/IPS) to monitor and block malformed or suspicious SIP authentication attempts. 5. Regularly audit and monitor logs for unusual authentication failures or malformed SIP messages that could indicate exploitation attempts. 6. Apply principle of least privilege to the systems running PJSIP to limit the impact of potential exploitation. 7. Educate network and security teams about this specific vulnerability to ensure rapid detection and response if exploitation attempts occur.
For access to advanced analysis and higher rate limits, contact root@offseq.com
Technical Details
- Data Version
- 5.1
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2022-02-10T00:00:00.000Z
- Cisa Enriched
- true
Threat ID: 682d9842c4522896dcbf2773
Added to database: 5/21/2025, 9:09:22 AM
Last enriched: 6/23/2025, 2:42:41 PM
Last updated: 7/30/2025, 11:48:01 PM
Views: 12
Related Threats
CVE-2025-8293: CWE-79 Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in Theerawat Patthawee Intl DateTime Calendar
MediumCVE-2025-7686: CWE-352 Cross-Site Request Forgery (CSRF) in lmyoaoa weichuncai(WP伪春菜)
MediumCVE-2025-7684: CWE-352 Cross-Site Request Forgery (CSRF) in remysharp Last.fm Recent Album Artwork
MediumCVE-2025-7683: CWE-352 Cross-Site Request Forgery (CSRF) in janyksteenbeek LatestCheckins
MediumCVE-2025-7668: CWE-352 Cross-Site Request Forgery (CSRF) in timothyja Linux Promotional Plugin
MediumActions
Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.
External Links
Need enhanced features?
Contact root@offseq.com for Pro access with improved analysis and higher rate limits.