SRTP doesn't define a specific port. Instead, Secure Real-time Transport Protocol (SRTP) utilizes the same ports as the Real-time Transport Protocol (RTP). RTP, and therefore SRTP, commonly uses UDP ports in the range of 1024 to 65535. The exact port number used for a specific SRTP session is negotiated between the communicating parties.
Here's a breakdown:
-
SRTP is an Extension of RTP: SRTP is essentially a security layer added to the RTP protocol. It uses RTP for the underlying transport mechanism.
-
Dynamic Port Assignment: Both RTP and SRTP use dynamic port assignment. This means that the specific ports used for a session are negotiated and assigned at the beginning of the communication. They are not fixed.
-
UDP as the Typical Transport: While RTP can technically run over other transport protocols, it most commonly uses UDP (User Datagram Protocol). This is because UDP offers lower overhead and is well-suited for real-time applications. Therefore, SRTP typically also runs over UDP.
-
Port Range: The Internet Assigned Numbers Authority (IANA) recommends using the dynamic port range of 49152 to 65535. However, older or simpler implementations often use the range of 1024 to 65535.
-
Control Protocol (SRTCP): Alongside SRTP for the media stream, there's also SRTCP (Secure Real-time Transport Control Protocol). SRTCP is the secure version of RTCP and manages control information (e.g., quality of service, participant information) and uses a separate port, often the next higher odd-numbered port to its associated SRTP stream. For instance, if SRTP uses UDP port 5000, SRTCP might use UDP port 5001.
In summary, there's no single "SRTP port." SRTP uses the same dynamically assigned UDP ports as RTP, negotiated during session setup. SRTCP, which handles control data, uses a related port.