WebRTC ICE连接因recvonly而失败

时间:2016-01-06 13:01:36

标签: webrtc sdp

我正在开发一款通过jingle和focus控制器连接到Jitsi Videobridge的应用程序。我现在要努力的是,客户端无需提供媒体即可加入,但仍可接收媒体,并打开数据通道。网桥和焦点生成一个发送给客户端的提议,将音频/视频设置为sendonly(我也尝试使用sendrecv)。客户端处理要约,创建和回答,并且没有错误地响应。 ICE候选人被收集,但IceConnectionState永远不会改变为连接,最终(我相信2分钟)超时并且失败。

我想知道rtcp-mux或捆绑是否可能导致此问题?当使用单向(sendonly / recvonly)rtp流进行多路复用/捆绑时,我不太清楚数据通道连接的工作原理。

这是一些SDP:

RemoteDescription商品(来自网桥)

type: offer, sdp: v=0
o=- 1451597730291 1451597731147 IN IP4 0.0.0.0
s=-
t=0 0
a=msid-semantic: WMS *
a=group:BUNDLE video audio data
m=video 1 RTP/SAVPF 100 116 117
c=IN IP4 0.0.0.0
a=rtcp:1 IN IP4 0.0.0.0
a=ice-ufrag:8gfh61a7svf4ec
a=ice-pwd:136r608m5cen22ivcql6l9gvbm
a=fingerprint:sha-1 CC:3E:77:73:76:E3:30:D2:A2:79:22:28:48:39:21:3F:11:29:23:01
a=setup:actpass
a=sendonly
a=mid:video
a=msid:w0KGB1MSiN5gP61DjvuwtcG3lJ061UYAsbil a0faf67d-6b50-4ac3-bf19-7cbf603eb7d0
a=rtcp-mux
a=rtpmap:100 VP8/90000
a=rtcp-fb:100 ccm fir
a=rtcp-fb:100 nack
a=rtcp-fb:100 nack pli
a=rtcp-fb:100 goog-remb
a=rtpmap:116 red/90000
a=rtpmap:117 ulpfec/90000
a=extmap:2 urn:ietf:params:rtp-hdrext:toffset
a=extmap:3 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time
a=ssrc:683076867 cname:HrPWqRhS08rzyMXc
a=ssrc:683076867 msid:w0KGB1MSiN5gP61DjvuwtcG3lJ061UYAsbil a0faf67d-6b50-4ac3-bf19-7cbf603eb7d0
a=candidate:1 1 SSLTCP 2130706431 <redacted ip> 4443 typ host generation 0
a=candidate:2 1 SSLTCP 2130706431 <redacted ip> 4443 typ host generation 0
a=candidate:3 1 SSLTCP 2113932031 <redacted ip> 4443 typ host generation 0
a=candidate:4 1 UDP 2113932031 <redacted ip> 10000 typ host generation 0
a=candidate:5 1 UDP 2113932031 <redacted ip> 10000 typ host generation 0
a=candidate:6 1 UDP 2113932031 <redacted ip> 10000 typ host generation 0
m=audio 1 RTP/SAVPF 111 103 104 9 0 8
c=IN IP4 0.0.0.0
a=rtcp:1 IN IP4 0.0.0.0
a=ice-ufrag:8gfh61a7svf4ec
a=ice-pwd:136r608m5cen22ivcql6l9gvbm
a=fingerprint:sha-1 CC:3E:77:73:76:E3:30:D2:A2:79:22:28:48:39:21:3F:11:29:23:01
a=setup:actpass
a=sendonly
a=mid:audio
a=msid:w0KGB1MSiN5gP61DjvuwtcG3lJ061UYAsbil 9a9bfbf3-a668-4952-b283-b2f2733d6a42
a=rtcp-mux
a=rtpmap:111 opus/48000/2
a=fmtp:111 minptime=10
a=rtpmap:103 ISAC/16000
a=rtpmap:104 ISAC/32000
a=rtpmap:9 G722/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level
a=extmap:3 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time
a=ssrc:3480057974 cname:HrPWqRhS08rzyMXc
a=ssrc:3480057974 msid:w0KGB1MSiN5gP61DjvuwtcG3lJ061UYAsbil 9a9bfbf3-a668-4952-b283-b2f2733d6a42
a=candidate:1 1 SSLTCP 2130706431 <redacted ip> 4443 typ host generation 0
a=candidate:2 1 SSLTCP 2130706431 <redacted ip> 4443 typ host generation 0
a=candidate:3 1 SSLTCP 2113932031 <redacted ip> 4443 typ host generation 0
a=candidate:4 1 UDP 2113932031 <redacted ip> 10000 typ host generation 0
a=candidate:5 1 UDP 2113932031 <redacted ip> 10000 typ host generation 0
a=candidate:6 1 UDP 2113932031 <redacted ip> 10000 typ host generation 0
m=application 1 DTLS/SCTP 5000
c=IN IP4 0.0.0.0
a=ice-ufrag:8gfh61a7svf4ec
a=ice-pwd:136r608m5cen22ivcql6l9gvbm
a=fingerprint:sha-1 CC:3E:77:73:76:E3:30:D2:A2:79:22:28:48:39:21:3F:11:29:23:01
a=setup:actpass
a=sctpmap:5000 webrtc-datachannel 1024
a=mid:data
a=candidate:1 1 SSLTCP 2130706431 <redacted ip> 4443 typ host generation 0
a=candidate:2 1 SSLTCP 2130706431 <redacted ip> 4443 typ host generation 0
a=candidate:3 1 SSLTCP 2113932031 <redacted ip> 4443 typ host generation 0
a=candidate:4 1 UDP 2113932031 <redacted ip> 10000 typ host generation 0
a=candidate:5 1 UDP 2113932031 <redacted ip> 10000 typ host generation 0
a=candidate:6 1 UDP 2113932031 <redacted ip> 10000 typ host generation 0

LocalDescription回答

type: answer, sdp: v=0
o=- 2333803414518268558 2 IN IP4 127.0.0.1
s=-
t=0 0
a=group:BUNDLE video audio data
a=msid-semantic: WMS
m=video 9 RTP/SAVPF 100 116 117
c=IN IP4 0.0.0.0
a=rtcp:9 IN IP4 0.0.0.0
a=ice-ufrag:YA6WpIjbnRubAMJx
a=ice-pwd:1sz5aZF90R00c/1CDZ8uqkn0
a=fingerprint:sha-256 7E:22:9D:86:4F:03:2E:43:58:B6:95:59:BE:82:B2:C8:1B:AB:5F:10:9E:B2:3F:9D:CD:2B:4D:59:BA:D6:C1:6E
a=setup:active
a=mid:video
a=extmap:2 urn:ietf:params:rtp-hdrext:toffset
a=extmap:3 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time
a=recvonly
a=rtcp-mux
a=rtpmap:100 VP8/90000
a=rtcp-fb:100 ccm fir
a=rtcp-fb:100 nack
a=rtcp-fb:100 nack pli
a=rtcp-fb:100 goog-remb
a=rtpmap:116 red/90000
a=rtpmap:117 ulpfec/90000
m=audio 9 RTP/SAVPF 111 103 104 9 0 8
c=IN IP4 0.0.0.0
a=rtcp:9 IN IP4 0.0.0.0
a=ice-ufrag:YA6WpIjbnRubAMJx
a=ice-pwd:1sz5aZF90R00c/1CDZ8uqkn0
a=fingerprint:sha-256 7E:22:9D:86:4F:03:2E:43:58:B6:95:59:BE:82:B2:C8:1B:AB:5F:10:9E:B2:3F:9D:CD:2B:4D:59:BA:D6:C1:6E
a=setup:active
a=mid:audio
a=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level
a=extmap:3 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time
a=recvonly
a=rtcp-mux
a=rtpmap:111 opus/48000/2
a=fmtp:111 minptime=10; useinbandfec=1
a=rtpmap:103 ISAC/16000
a=rtpmap:104 ISAC/32000
a=rtpmap:9 G722/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=maxptime:60
m=application 9 DTLS/SCTP 5000
c=IN IP4 0.0.0.0
b=AS:30
a=ice-ufrag:YA6WpIjbnRubAMJx
a=ice-pwd:1sz5aZF90R00c/1CDZ8uqkn0
a=fingerprint:sha-256 7E:22:9D:86:4F:03:2E:43:58:B6:95:59:BE:82:B2:C8:1B:AB:5F:10:9E:B2:3F:9D:CD:2B:4D:59:BA:D6:C1:6E
a=setup:active
a=mid:data
a=sctpmap:5000 webrtc-datachannel 1024

有趣的是,我注意到的一件事是,我似乎只是获得视频的ICE候选者,但它们应该是完全相同的,因为它是捆绑的,对吗?

0 个答案:

没有答案