PCMU RTP数据包有效负载具有额外的数据长度

时间:2016-07-10 08:08:42

标签: size rtp pcm payload

我监控WebRTC会话,发现额外的未知(我不知道)数据,现在我正在编写相同的RTP音频会话,我需要知道原因。

将PCMU(8bit,mono,8000Hz)帧发送到WebRTC浏览器客户端,每帧为20 ms,因此有效载荷大小= 8000Hz * 1Byte(8bit)* 20ms / 1000ms = 160字节,但在客户端接收170字节(可以从WireShark看到):

Frame 34012: 236 bytes on wire (1888 bits), 236 bytes captured (1888 bits) on interface 0
Ethernet II, Src: Tp-LinkT_4d:01:68 (e4:d3:32:4d:01:68), Dst: IntelCor_cb:c6:7c (24:77:03:cb:c6:7c)
Internet Protocol Version 4, Src: 111.198.38.42, Dst: 192.168.1.103
User Datagram Protocol, Src Port: 48244 (48244), Dst Port: 55003 (55003)
Real-Time Transport Protocol
    10.. .... = Version: RFC 1889 Version (2)
    ..0. .... = Padding: False
    ...1 .... = Extension: True
    .... 0000 = Contributing source identifiers count: 0
    0... .... = Marker: False
    Payload type: ITU-T G.711 PCMU (0)
    Sequence number: 36871
    Timestamp: 1038276488
    Synchronization Source identifier: 0x4994b249 (1234481737)
    Defined by profile: Unknown (0xbede)
    Extension length: 2
    Header extensions
    Payload: 8037d1facad8535b355510e6b6880e8700eabfaed41c34b7...

额外的10(170-160)字节来自哪里? where is the extra 10 (170-160) bytes from?

2 个答案:

答案 0 :(得分:0)

rtp头扩展位已设置,因此可能有10个额外字节。很有可能它的" urn:ietf:params:rtp-hdrext:ssrc-audio-level"扩展,如果您从webrtc端点获取音频。看看https://tools.ietf.org/html/rfc6464

答案 1 :(得分:0)

可能是SRTP auth标签,如果使用80位,则为10个字节。

相关问题