Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remote SessionDescription semantics does not match configuration: Expected UnifiedPlan, but RemoteDescription is PlanB #2970

Open
philn opened this issue Dec 13, 2024 · 3 comments

Comments

@philn
Copy link

philn commented Dec 13, 2024

Your environment.

  • Version: 3.3.4 (livekit 1.8.0)
  • Browser: experimental webkitgtk build with gstwebrtc enabled
  • Other Information - stacktraces, related issues, suggestions how to fix, links for us to have context

What did you do?

Trying to connect to a locally-deployed livekit meet server, this SDP is detected a PlanB:

v=0
o=- 8721044706072616390 0 IN IP4 0.0.0.0
s=-
t=0 0
a=ice-options:trickle
a=group:BUNDLE audio0 video1 application2
m=audio 9 UDP/TLS/RTP/SAVPF 96 9 0 8 110 111 112 113
c=IN IP4 0.0.0.0
a=rtpmap:96 OPUS/48000/2
a=rtpmap:9 G722/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:110 red/48000
a=rtpmap:111 ulpfec/48000
a=rtpmap:112 rtx/48000
a=rtpmap:113 rtx/48000
a=fmtp:96 minptime=10;useinbandfec=1
a=fmtp:112 apt=96
a=fmtp:113 apt=110
a=rtcp-fb:96 nack
a=rtcp-fb:96 transport-cc
a=rtcp-fb:9 nack
a=rtcp-fb:9 transport-cc
a=rtcp-fb:0 nack
a=rtcp-fb:0 transport-cc
a=rtcp-fb:8 nack
a=rtcp-fb:8 transport-cc
a=extmap:1 http://www.ietf.org/id/draft-holmer-rmcat-transport-wide-cc-extensions-01
a=extmap:2 urn:ietf:params:rtp-hdrext:sdes:mid
a=extmap:3 urn:ietf:params:rtp-hdrext:sdes:repaired-rtp-stream-id
a=extmap:4 urn:ietf:params:rtp-hdrext:sdes:rtp-stream-id
a=extmap:5 urn:ietf:params:rtp-hdrext:ssrc-audio-level
a=setup:actpass
a=mid:audio0
a=msid:d4dcc506-5542-4f36-afdb-1d9a33c9c6ca 14bac30b-61d9-45eb-9a2c-96d9d80ca56c
a=sendonly
a=ice-ufrag:P2e72cTklZQmw6lW1pTbwDgasAR7jTkS
a=ice-pwd:HODw/p+ARG6dyGB5Iw+nEBOKF+UwSWUr
a=fingerprint:sha-256 85:BD:29:6C:F8:67:8D:A1:9A:FF:28:CB:B5:30:2B:86:CC:D9:29:F1:80:CD:E9:36:6B:54:5A:17:B0:32:45:D6
a=ssrc:2412112442 msid:user2780343522@host-c8ae0a48 webrtctransceiver0
a=ssrc:2412112442 cname:user2780343522@host-c8ae0a48
a=ssrc:2009240965 msid:user2780343522@host-c8ae0a48 webrtctransceiver0
a=ssrc:2009240965 cname:user2780343522@host-c8ae0a48
a=ssrc:4258407968 msid:user2780343522@host-c8ae0a48 webrtctransceiver0
a=ssrc:4258407968 cname:user2780343522@host-c8ae0a48
a=ssrc:1905531733 msid:user2780343522@host-c8ae0a48 webrtctransceiver0
a=ssrc:1905531733 cname:user2780343522@host-c8ae0a48
a=ssrc:2253869690 msid:user2780343522@host-c8ae0a48 webrtctransceiver0
a=ssrc:2253869690 cname:user2780343522@host-c8ae0a48
a=ssrc-group:FID 2412112442 2253869690
a=rtcp-mux
a=rtcp-rsize
m=video 0 UDP/TLS/RTP/SAVPF 108 109 97 98 99 100 101 102 103 104 105 106 107 114
c=IN IP4 0.0.0.0
a=rtpmap:97 H264/90000
a=rtpmap:98 H264/90000
a=rtpmap:99 H264/90000
a=rtpmap:100 H264/90000
a=rtpmap:101 H264/90000
a=rtpmap:102 H264/90000
a=rtpmap:103 H264/90000
a=rtpmap:104 H264/90000
a=rtpmap:105 H265/90000
a=rtpmap:106 AV1/90000
a=rtpmap:107 VP8/90000
a=rtpmap:108 VP9/90000
a=rtpmap:109 VP9/90000
a=rtpmap:114 rtx/90000
a=fmtp:97 level-asymmetry-allowed=1;packetization-mode=1;profile-level-id=42e01f
a=fmtp:98 level-asymmetry-allowed=1;packetization-mode=0;profile-level-id=42e01f
a=fmtp:99 level-asymmetry-allowed=1;packetization-mode=1;profile-level-id=640c1f
a=fmtp:100 level-asymmetry-allowed=1;packetization-mode=0;profile-level-id=640c1f
a=fmtp:101 level-asymmetry-allowed=1;packetization-mode=1;profile-level-id=42001f
a=fmtp:102 level-asymmetry-allowed=1;packetization-mode=0;profile-level-id=42001f
a=fmtp:103 level-asymmetry-allowed=1;packetization-mode=1;profile-level-id=4d001f
a=fmtp:104 level-asymmetry-allowed=1;packetization-mode=0;profile-level-id=4d001f
a=fmtp:108 profile-id=0
a=fmtp:109 profile-id=2
a=fmtp:114 apt=97
a=rtcp-fb:97 nack
a=rtcp-fb:97 nack pli
a=rtcp-fb:97 ccm fir
a=rtcp-fb:97 transport-cc
a=rtcp-fb:98 nack
a=rtcp-fb:98 nack pli
a=rtcp-fb:98 ccm fir
a=rtcp-fb:98 transport-cc
a=rtcp-fb:99 nack
a=rtcp-fb:99 nack pli
a=rtcp-fb:99 ccm fir
a=rtcp-fb:99 transport-cc
a=rtcp-fb:100 nack
a=rtcp-fb:100 nack pli
a=rtcp-fb:100 ccm fir
a=rtcp-fb:100 transport-cc
a=rtcp-fb:101 nack
a=rtcp-fb:101 nack pli
a=rtcp-fb:101 ccm fir
a=rtcp-fb:101 transport-cc
a=rtcp-fb:102 nack
a=rtcp-fb:102 nack pli
a=rtcp-fb:102 ccm fir
a=rtcp-fb:102 transport-cc
a=rtcp-fb:103 nack
a=rtcp-fb:103 nack pli
a=rtcp-fb:103 ccm fir
a=rtcp-fb:103 transport-cc
a=rtcp-fb:104 nack
a=rtcp-fb:104 nack pli
a=rtcp-fb:104 ccm fir
a=rtcp-fb:104 transport-cc
a=rtcp-fb:105 nack
a=rtcp-fb:105 nack pli
a=rtcp-fb:105 ccm fir
a=rtcp-fb:105 transport-cc
a=rtcp-fb:106 nack
a=rtcp-fb:106 nack pli
a=rtcp-fb:106 ccm fir
a=rtcp-fb:106 transport-cc
a=rtcp-fb:107 nack
a=rtcp-fb:107 nack pli
a=rtcp-fb:107 ccm fir
a=rtcp-fb:107 transport-cc
a=rtcp-fb:108 nack
a=rtcp-fb:108 nack pli
a=rtcp-fb:108 ccm fir
a=rtcp-fb:108 transport-cc
a=rtcp-fb:109 nack
a=rtcp-fb:109 nack pli
a=rtcp-fb:109 ccm fir
a=rtcp-fb:109 transport-cc
a=extmap:1 http://www.ietf.org/id/draft-holmer-rmcat-transport-wide-cc-extensions-01
a=extmap:2 urn:ietf:params:rtp-hdrext:sdes:mid
a=extmap:3 urn:ietf:params:rtp-hdrext:sdes:repaired-rtp-stream-id
a=extmap:4 urn:ietf:params:rtp-hdrext:sdes:rtp-stream-id
a=extmap:5 http://www.webrtc.org/experiments/rtp-hdrext/color-space
a=extmap:6 https://aomediacodec.github.io/av1-rtp-spec/#dependency-descriptor-rtp-header-extension
a=setup:actpass
a=mid:video1
a=msid:fecc8f07-1e45-4491-9078-fecbf715dadb 621a2696-6db5-430f-b885-a2fd98a208f2
a=sendonly
a=ice-ufrag:P2e72cTklZQmw6lW1pTbwDgasAR7jTkS
a=ice-pwd:HODw/p+ARG6dyGB5Iw+nEBOKF+UwSWUr
a=fingerprint:sha-256 85:BD:29:6C:F8:67:8D:A1:9A:FF:28:CB:B5:30:2B:86:CC:D9:29:F1:80:CD:E9:36:6B:54:5A:17:B0:32:45:D6
a=ssrc:578602538 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:578602538 cname:user2780343522@host-c8ae0a48
a=ssrc:1960793915 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:1960793915 cname:user2780343522@host-c8ae0a48
a=ssrc:890918086 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:890918086 cname:user2780343522@host-c8ae0a48
a=ssrc:1454815906 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:1454815906 cname:user2780343522@host-c8ae0a48
a=ssrc:3834637145 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:3834637145 cname:user2780343522@host-c8ae0a48
a=ssrc:2256176958 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:2256176958 cname:user2780343522@host-c8ae0a48
a=ssrc:1364677151 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:1364677151 cname:user2780343522@host-c8ae0a48
a=ssrc:3843409207 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:3843409207 cname:user2780343522@host-c8ae0a48
a=ssrc:288295172 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:288295172 cname:user2780343522@host-c8ae0a48
a=ssrc:123532235 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:123532235 cname:user2780343522@host-c8ae0a48
a=ssrc:1783185158 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:1783185158 cname:user2780343522@host-c8ae0a48
a=ssrc:1550974677 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:1550974677 cname:user2780343522@host-c8ae0a48
a=ssrc:2936330432 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:2936330432 cname:user2780343522@host-c8ae0a48
a=ssrc:2217239020 msid:user2780343522@host-c8ae0a48 webrtctransceiver1
a=ssrc:2217239020 cname:user2780343522@host-c8ae0a48
a=ssrc-group:FID 578602538 2217239020
a=rtcp-mux
a=rtcp-rsize
a=bundle-only
m=application 0 UDP/DTLS/SCTP webrtc-datachannel
c=IN IP4 0.0.0.0
a=setup:actpass
a=mid:application2
a=ice-ufrag:P2e72cTklZQmw6lW1pTbwDgasAR7jTkS
a=ice-pwd:HODw/p+ARG6dyGB5Iw+nEBOKF+UwSWUr
a=fingerprint:sha-256 85:BD:29:6C:F8:67:8D:A1:9A:FF:28:CB:B5:30:2B:86:CC:D9:29:F1:80:CD:E9:36:6B:54:5A:17:B0:32:45:D6
a=bundle-only
a=sctp-port:5000

What did you expect?

Unified plan ;)

What happened?

@Sean-Der
Copy link
Member

Instead of a regex this should just explicitly check for audio, video or data.

I will open a PR for that @philn !

@Sean-Der
Copy link
Member

Hey @philn

Sorry I was wrong. This SDP is Plan-B (I believe?)

The multiple a=ssrc lines in the video media section would cause it be parsed as Plan-B. The all have the same cname/msid though.

This is a strange bug. Is it easy to get LiveKit to produce an SDP like this?

@philn
Copy link
Author

philn commented Dec 16, 2024

In the unified plan proposal, section 3.3 there's this:

In cases where a media source needs to correspond to more than one
RTP flow, e.g. RTX, FEC, or simulcast, the a=ssrc-group [RFC5576]
concept is used to create a grouping of SSRCs for a single media
stream track. Each SSRC is declared using a=ssrc attributes, the
same MSID is shared between the SSRCs, and the a=ssrc-group attribute
defines the behavior of the grouped SSRCs.

So iiuc, having the same MSID should be OK in unified plan?

This is not trivial to reproduce, you'd need a development build of webkitgtk with a specific branch (that i can share) and a locally deployed livekit instance (so that the livekit/pion logs are visible).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants