Xirsys.XTurn.Actions.HasRequestedTransport (xturn v2.0.0)

Copy Markdown View Source

Guard that validates REQUESTED-TRANSPORT on Allocate.

What problem this solves

Allocate must declare whether the relay uses UDP or TCP. This step rejects missing, unsupported, or mismatched transport requests (for example TCP relay on a UDP socket) before any relay resources are opened.

First step in the @allocation pipeline.

Internal

Pipeline action only; not part of the public application API.

RFCs

Summary

Functions

Ensures REQUESTED-TRANSPORT is present and UDP/TCP is allowed on this socket.

Functions

process(conn)

Ensures REQUESTED-TRANSPORT is present and UDP/TCP is allowed on this socket.

Passes conn through on success; returns conn with 400 or 442 error response when the attribute is missing, unsupported, or TCP is requested on a datagram socket.