-
- All Implemented Interfaces:
-
org.ice4j.socket.DatagramPacketFilter
public class RtcpDemuxPacketFilter implements DatagramPacketFilter
Implements a DatagramPacketFilter which only accepts DatagramPackets which represent RTCP messages according to the rules described in RFC5761.
-
-
Method Summary
Modifier and Type Method Description static booleanisRtcpPacket(DatagramPacket p)Determines whether a specific DatagramPacket is an RTCP. booleanaccept(DatagramPacket p)Returns true if this RtcpDemuxPacketFilter should accept p, that is, if p looks like an RTCP packet. -
-
Method Detail
-
isRtcpPacket
static boolean isRtcpPacket(DatagramPacket p)
Determines whether a specific DatagramPacket is an RTCP. DatagramPacket in a selection based on this filter. RTP/RTCP packets are distinguished from other packets (such as STUN, DTLS or ZRTP) by the value of their first byte. See RFC5764, Section 5.1.2 and RFC6189, Section 5. RTCP packets are distinguished from RTP packet based on the second byte (either Packet Type (RTCP) or M-bit and Payload Type (RTP). See RFC5761, Section 4 We assume that RTCP packets have a packet type in [200, 211]. This means that RTP packets with Payload Types in [72, 83] (which should not appear, because these PTs are reserved or unassigned by IANA, see IANA RTP Parameters) with the M-bit set will be misidentified as RTCP packets. Also, any RTCP packets with Packet Types not in [200, 211] will be misidentified as RTP packets.
- Parameters:
p- the DatagramPacket whose protocol we'd like to determine.
-
accept
boolean accept(DatagramPacket p)
Returns true if this RtcpDemuxPacketFilter should accept p, that is, if p looks like an RTCP packet. See isRtcpPacket
-
-
-
-