CVE-2026-57162

PJSIP: Stack overflow parsing SDP a=crypto attributes

Published Sep 4, 2026 CVSS 4.0 · 8.8 High EPSS < 1% KEV · Not listed
Description
PJSIP is a free and open source multimedia communication library written in C. Prior to commit a1b707c, a stack buffer overflow exists in the SRTP/SDES media transport when processing a=crypto attributes during SDP offer/answer (sdes_encode_sdp() in transport_srtp_sdes.c). This affects applications with SRTP enabled (use_srtp optional or mandatory, using SDES keying). During media negotiation, the crypto attributes from the remote SDP are collected into a fixed-size array without bounding their number; a remote peer that includes an excessive number of a=crypto attributes in a single media description can write past the end of that array on the stack. This is reachable from an incoming SIP INVITE during offer/answer, before application-level authentication. Impact may range from unexpected application termination to control flow hijack/memory corruption. Applications that do not enable SRTP are not affected. This issue has been patched via commit a1b707c.

Analysis

AI-generated

Technical impact

The vulnerability is a stack buffer overflow that occurs in PJSIP’s SRTP/SDES media transport when the function that parses a=crypto attributes in an SDP message receives more attributes than the fixed‑size array can hold. The overflow can corrupt the stack, leading to program termination or, if an attacker can control the overflowed data, potential hijacking of control flow and execution of arbitrary code. This flaw is identified as CWE‑121. The lack of bounds checking means that the attacker does not need to bypass authentication; the overflow can be triggered by a normal SIP INVITE that includes a malicious SDP during offer/answer negotiating media.

Affected Systems

All installations of pjproject that have SRTP enabled with SDES keying are affected. The issue exists in every version prior to the patch commit a1b707c. Applications or deployments that do not enable SRTP, or that use SRTP with keying methods other than SDES, are not impacted.

Risk and Exploitability

With a CVSS score of 8.8 the flaw is high severity, but EPSS data is unavailable and it is not listed in the CISA KEV catalog. Because the vulnerability is reachable from an unauthenticated SIP INVITE during the SIP Offer/Answer phase before application‑level authentication, an attacker can craft a message that triggers the buffer overflow. The lack of a mitigated code path and the potential for control‑flow hijacking make the risk significant, especially for systems exposed to the Internet or other untrusted networks.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade to a PJSIP release that includes or incorporates commit a1b707c or otherwise applies the patch that bounds the number of a=crypto attributes processed.
  • If upgrading is not feasible, reconfigure the application to disable SRTP or SDES keying so that the vulnerable parsing routine is never reached.
  • Add a defensive input validation step that limits the number of a=crypto attributes accepted from any remote SDP before further processing, thereby preventing buffer overflows.

Generated by OpenCVE AI on September 4, 2026 at 19:33 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
First Time appeared Teluu
Teluu pjsip
CPEs cpe:2.3:a:teluu:pjsip:*:*:*:*:*:*:*:*
Vendors & Products Teluu
Teluu pjsip
Metrics cvssV3_1

{'score': 9.1, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H'}

Type Values Removed Values Added
First Time appeared Pjsip
Pjsip pjproject
Vendors & Products Pjsip
Pjsip pjproject
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description PJSIP is a free and open source multimedia communication library written in C. Prior to commit a1b707c, a stack buffer overflow exists in the SRTP/SDES media transport when processing a=crypto attributes during SDP offer/answer (sdes_encode_sdp() in transport_srtp_sdes.c). This affects applications with SRTP enabled (use_srtp optional or mandatory, using SDES keying). During media negotiation, the crypto attributes from the remote SDP are collected into a fixed-size array without bounding their number; a remote peer that includes an excessive number of a=crypto attributes in a single media description can write past the end of that array on the stack. This is reachable from an incoming SIP INVITE during offer/answer, before application-level authentication. Impact may range from unexpected application termination to control flow hijack/memory corruption. Applications that do not enable SRTP are not affected. This issue has been patched via commit a1b707c.
Title PJSIP: Stack overflow parsing SDP a=crypto attributes
Weaknesses CWE-121
References
Metrics cvssV4_0

{'score': 8.8, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:H/SC:N/SI:N/SA:N'}

Weaknesses
  • CWE-121

    Stack-based Buffer Overflow

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Sep 4, 2026, 5:26 PM
Reserved
Jun 24, 2026, 1:47 AM
Status
Analyzed
Published
Sep 4, 2026, 6:17 PM
Modified
Sep 11, 2026, 3:51 PM