GHSA-pfvm-w89x-94jw: High severity nuget/SIPSorcery vulnerability

Published Aug 12, 2026
·
Updated

Summary TurnServer.ReceiveUdpAsync places its generic catch (Exception) OUTSIDE the while receive loop, and Start() launches the loop fire-and-forget with no supervision or restart. A single pre-authentication UDP datagram whose STUN header first byte is in 0x80–0xFF causes STUNHeader.ParseSTUNHeader to throw ApplicationException, which unwinds past the loop and terminates it. The TURN UDP relay is then dead for ALL clients until the process is restarted.

Root Cause src/SIPSorcery/net/TURN/TurnServer.cs: - ReceiveUdpAsync (:555-577): the inner try (:562-567) wraps only udpSocket.ReceiveAsync(); HandleUdpDatagram(result.Buffer, result.RemoteEndPoint) (:569) is inside the while body but OUTSIDE that inner try. The generic catch (Exception ex) (:573) is lexically OUTSIDE the while. - Start() does = ReceiveUdpAsync(); (:381) — fire-and-forget, no restart. - HandleUdpDatagram (:579) calls STUNMessage.ParseSTUNMessage(data, data.Length) (:600) for any non-ChannelData datagram; ParseSTUNMessage (STUNMessage.cs:94) has no try/catch.

Impact ApplicationException propagates out of the while, is caught at :573, logged, and the method returns. running remains true but nothing re-invokes ReceiveUdpAsync → TURN UDP relay permanently unavailable for all clients (whole-server DoS). Pre-authentication: STUN parsing precedes any TURN allocation/credential check.

Proof of Concept Send one UDP datagram to the TURN port (default 3478) with first byte 0x80 (e.g. 80 00 00 00). 0x80 & 0xC0 = 0x80 ≠ 0x40 → not ChannelData → ParseSTUNMessage → ParseSTUNHeader executes if ((Array[startIndex] & 0xC0) != 0) throw new ApplicationException(...) (STUNHeader.cs:169-172); 0x80 & 0xC0 = 0x80 ≠ 0 → throws.

Attack Chain 1. Entry: one UDP datagram to the TURN port, first byte 0x80–0xFF. Guard: ChannelData branch requires (data[0] & 0xC0) == 0x40 (:583). Bypass: 0x80 & 0xC0 = 0x80 ≠ 0x40 → falls through to ParseSTUNMessage (:600). 2. Sink: STUNMessage.ParseSTUNMessage → STUNHeader.ParseSTUNHeader (STUNHeader.cs:169-172) throws ApplicationException. Guard: none before the throw; ParseSTUNMessage has no try/catch. Bypass: 0x80 & 0xC0 = 0x80 ≠ 0 → throws. 3. Impact: exception unwinds past the while into catch(Exception) at :573 → logged → method returns → loop exits. Guard: none — no restart (Start() :381 fire-and-forget). Bypass: N/A. TURN UDP relay dead for all clients until process restart.

Bypass Evidence - Loop/catch structure: catch at TurnServer.cs:573 is outside the while at :559; HandleUdpDatagram at :569 is outside the inner try (:562-567). - Unguarded ParseSTUNMessage at :600; throw at STUNHeader.cs:169-172. - Fire-and-forget start at :381 with no restart in Start(). - TurnServerConfig.ListenAddress defaults to IPAddress.Loopback (:42), but a functioning TURN server must bind a routable address to serve clients, so real deployments are exposed. Non-default config narrows the vulnerable population, not the attack difficulty → AC:L.

Affected Versions nuget:SIPSorcery <= 10.0.13 (TurnServer component present since 10.0.5; verified on release tag v10.0.13 and HEAD).

Dedup NOT a duplicate of GHSA-28gm-jrmw-xx93 (CVE-2026-54632), which covers the client RTP/ICE socket (UdpReceiver/RTPChannel). TurnServer is a distinct shipped RFC 5766 server component with its own loop and fix location.

Suggested Fix Wrap HandleUdpDatagram in a per-datagram try/log-and-continue INSIDE the while (matching the drop-and-continue intent of fix bdb76cb), and/or add loop supervision/restart.

--- Reported by zx (Jace) — GitHub: @manus-use

Affected Software

1 affected componentFixes available
nuget/SIPSorcery>=10.0.5<=10.0.13
10.0.14

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade nuget/SIPSorcery to a version that resolves this vulnerability.

    Fixed in 10.0.14
  2. Upgrade

    Upgrade nuget:SIPSorcery (TurnServer component) to a version that resolves this vulnerability.

    Fixed in 10.0.13
  3. Compensating control

    Restrict network access to the TURN server UDP port (default 3478) so only trusted clients/relays can send pre-authentication UDP datagrams to it.

Event History

Aug 12, 2026
Advisory Published
via GitHub·07:31 PM
Data Sourced
via GitHub·07:31 PM
DescriptionSeverityWeaknessAffected Software
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of GHSA-pfvm-w89x-94jw?

The severity of GHSA-pfvm-w89x-94jw is high with a score of 7.5.

2

What software is affected by GHSA-pfvm-w89x-94jw?

The affected software is nuget/SIPSorcery.

3

How do I fix GHSA-pfvm-w89x-94jw?

To fix GHSA-pfvm-w89x-94jw, it is recommended to apply the latest security updates provided by the SIPSorcery maintainers.

4

What type of vulnerability is GHSA-pfvm-w89x-94jw?

GHSA-pfvm-w89x-94jw is a vulnerability related to improper exception handling in the UDP receive loop.

5

What are the potential impacts of GHSA-pfvm-w89x-94jw?

GHSA-pfvm-w89x-94jw can lead to denial of service due to unhandled exceptions caused by specific UDP packets.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203