/

CVE-2026-65981

Severity:

HIGH RISK

(7.1)

Authorization Bypass (CWE-639) in Coturn Mobility Mode

CVE-2026-65981

Received

Vulnerability type

Category:

Authorization Bypass

CWE:

CWE-639

Impact:

Traffic Hijacking and Quota Abuse

Severity:

HIGH RISK

(7.1)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

A logic flaw in Coturn's mobility feature allows authenticated attackers who obtain a victim's MOBILITY-TICKET to resume allocations using their own credentials instead of the original owner's.

Under these conditions, an attacker can receive and inject relayed traffic through the victim's allocation and consume the victim's TURN quota without being detected as impersonation.

Affected context

This vulnerability occurs in Coturn TURN/STUN servers configured with the --mobility option enabled and using long-term credentials.

It manifests during the handling of resumed REFRESH requests when allocations are resumed based solely on an attacker-controlled mobility identifier.

The risk is present when MOBILITY-TICKET values can be captured, reused, or otherwise obtained by an authenticated party who is not the original allocation owner.

Exploit preconditions

  • Attack surface: TURN REFRESH resume processing in mobility-enabled Coturn servers
  • Required access: Valid long-term credentials on the server and access to a victim's MOBILITY-TICKET
  • Trigger point: Sending a resumed REFRESH request using the victim's mobility identifier from an attacker-authenticated session
  • Why exploitation is possible: The resumed allocation is located using only the mobility ID, and the authorization check validates against the resuming user's identity rather than confirming that the requester matches the original allocation owner.

Why this happens

The root cause is an authorization logic error where allocation ownership is not revalidated during session resumption.

In the handle_turn_refresh resume branch, Coturn locates the victim's allocation using a mobile identifier controlled by the requester, then relies on existing authentication state (hmackey_set) to validate the REFRESH without confirming that the resuming session belongs to the allocation owner.

Because credentials are only copied when the resuming session is unauthenticated, a previously authenticated attacker can reuse their own identity while controlling the victim's allocation context.

This maps to CWE-639: Authorization Bypass Through User-Controlled Key, where a user-supplied token (mobility ID / MOBILITY-TICKET) is used as a lookup key without properly ensuring that the requester is the legitimate owner of the referenced resource.

Potential impact

  • An attacker may receive relayed traffic intended for the victim's TURN allocation.
  • An attacker can inject arbitrary traffic through the victim's allocation, potentially enabling spoofing or abuse.
  • The victim's TURN quota can be consumed, leading to denial of service or unexpected resource usage.
  • Logging and accounting may incorrectly attribute traffic to the victim, complicating incident response and auditing.

General mitigation guidance

Mitigation generally focuses on strengthening authorization checks around resource resumption and token-based mobility.

Recommended design patterns include:

  • Ensuring that any mobility or session-resumption identifier is bound to both the allocation and the original authenticated identity, and that both are checked on resume.
  • Treating resumption tokens (like MOBILITY-TICKETs) as sensitive bearer credentials, limiting their lifetime and scope, and requiring proof-of-possession or re-authentication when reused.
  • Resetting or revalidating authentication state when switching allocation contexts, rather than relying on prior hmackey_set flags alone.
  • Applying least-privilege principles to TURN allocations so that resumed sessions cannot escalate access beyond what the original owner had.
  • Designing server-side checks that reject resumption attempts when the requesting identity does not match the allocation owner, even if the requester is otherwise authenticated.

How teams detect issues like this

Detection efforts can focus on identifying authorization inconsistencies and suspicious mobility behavior:

  • Static analysis and code review can look for authorization flows where user-controlled identifiers (such as mobility IDs or tickets) are used to locate allocations or sessions without explicit owner verification.
  • Security-focused reviews of TURN/STUN server code should trace how authentication state flags (e.g., hmackey_set) influence decision-making and confirm that resource ownership is revalidated when resuming allocations.
  • Runtime monitoring can flag unusual patterns where traffic associated with a single allocation appears to be driven by multiple authenticated identities or where resumption events occur from unexpected clients.
  • Policy enforcement in CI/CD can require explicit checks tying resumption tokens to both resource identifiers and user identities, and can reject changes where authorization is inferred from prior state rather than recomputed per request.

Sources

SourceLink
github.comgithub.com/coturn/coturn/commit/37df0513168f830a7c9ce0a411db0300fa182f05
github.comgithub.com/coturn/coturn/security/advisories/GHSA-69wx-x7x6-pjj8

Frequently asked

questions

Exploitability depends on the attacker's ability to obtain a victim's MOBILITY-TICKET on a mobility-enabled Coturn server.

If such tickets can be captured or guessed in a given deployment, an attacker with valid credentials can hijack allocations; otherwise, the risk is limited to environments where ticket exposure is realistic.

The attacker must be an authenticated user on the Coturn server (long-term credentials) and must possess a valid MOBILITY-TICKET belonging to another user.

Without both authenticated access and a victim's mobility token, the vulnerability cannot be triggered.

The safest fix pattern is to bind allocations tightly to the authenticated identity and ensure that any resumption or mobility operation verifies that the requester is the original allocation owner.

Resumption tokens should not be sufficient on their own; authorization must re-check identity and reset or recompute authentication state for the resumed context.

Future designs should treat user-controlled identifiers and tickets as references, not authority, and always confirm resource ownership during any resume, refresh, or migration operation.

Consistent use of access-control checks tied to the authenticated user, combined with secure token lifecycle management and thorough code review for indirect references, can significantly reduce the risk of CWE-639 style vulnerabilities.

Find out what's already
exploitable in your codebase.