This repository has been archived by the owner on Mar 22, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 280
[question] 'Value does not fall within the expected range.' exception #844
Comments
Hey there. Did you find a solution for this? I am having a similar issue. "Value does not fall within the expected range." But I don't understand what's wrong. Here's the offer that throws the error. Could anyone have a quick look to see if something's off in the message? I've tested a bunch with different codecs, etc. but it's always the same result.
I'm also not a WebRTC expert, so debugging without any indication of where the error might come from is really hard for me. With my limited knowledge of the SDP process and googling a bunch it seems the offer should pass. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Describe the bug
I am trying to implement a C# desktop application on Windows which is able to connect to a remote peer and establish a WebRTC call. After calling the PeerConnection.SetRemoteDescriptionAsync() method with the SDP answer I get this exception: 'Value does not fall within the expected range.'
To Reproduce
The remote peer is managed by a web API. The remote peer expects me to pass the SDP offer to the web API so I just simply print the SDP offer to the output and send it manually to the API in a HTTP message using Postman. I receive the SDP answer in the body of the successful HTTP answer. So I copy it to the console, then the program reads it from the standard input and parses it to an SdpMessage object.
I am trying to make a connection with the following flow:
I have uploaded my code to a public repository so you can track step by step what I am trying to do:
https://github.com/levboy1/microsoft_mixedreality
SDP messages
Offer message
v=0 o=- 8795496105880237725 2 IN IP4 127.0.0.1 s=- t=0 0 a=group:BUNDLE audio data a=msid-semantic: WMS mrsw#0 m=audio 9 UDP/TLS/RTP/SAVPF 111 103 104 9 102 0 8 106 105 13 110 112 113 126 c=IN IP4 0.0.0.0 a=rtcp:9 IN IP4 0.0.0.0 a=ice-ufrag:20JD a=ice-pwd:JbJ1IiKjfEfpsgkNvDHlj9Wt a=ice-options:trickle a=fingerprint:sha-256 D0:FE:84:B4:90:0C:FA:A9:7A:AA:34:6A:D2:52:4F:35:9C:8D:E8:36:3C:17:65:40:81:74:F5:CA:BA:68:CB:91 a=setup:actpass a=mid:audio a=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level a=sendrecv a=rtcp-mux a=rtpmap:111 opus/48000/2 a=rtcp-fb:111 transport-cc a=fmtp:111 minptime=10;useinbandfec=1 a=rtpmap:103 ISAC/16000 a=rtpmap:104 ISAC/32000 a=rtpmap:9 G722/8000 a=rtpmap:102 ILBC/8000 a=rtpmap:0 PCMU/8000 a=rtpmap:8 PCMA/8000 a=rtpmap:106 CN/32000 a=rtpmap:105 CN/16000 a=rtpmap:13 CN/8000 a=rtpmap:110 telephone-event/48000 a=rtpmap:112 telephone-event/32000 a=rtpmap:113 telephone-event/16000 a=rtpmap:126 telephone-event/8000 a=ssrc:3462862450 cname:PkburLTo3Ytfmcfb a=ssrc:3462862450 msid:mrsw#0 437642e8-574b-4375-bd34-54efcec5a2b1 a=ssrc:3462862450 mslabel:mrsw#0 a=ssrc:3462862450 label:437642e8-574b-4375-bd34-54efcec5a2b1 m=application 9 DTLS/SCTP 5000 c=IN IP4 0.0.0.0 a=ice-ufrag:20JD a=ice-pwd:JbJ1IiKjfEfpsgkNvDHlj9Wt a=ice-options:trickle a=fingerprint:sha-256 D0:FE:84:B4:90:0C:FA:A9:7A:AA:34:6A:D2:52:4F:35:9C:8D:E8:36:3C:17:65:40:81:74:F5:CA:BA:68:CB:91 a=setup:actpass a=mid:data a=sctpmap:5000 webrtc-datachannel 1024 a=candidate:974510316 1 udp 2122260223 10.228.240.33 61827 typ host generation 0 ufrag 20JD network-id 1 a=candidate:948785377 1 udp 2122194687 192.168.0.154 61828 typ host generation 0 ufrag 20JD network-id 2 network-cost 10 a=candidate:974510316 1 udp 2122260223 10.228.240.33 61829 typ host generation 0 ufrag 20JD network-id 1 a=candidate:948785377 1 udp 2122194687 192.168.0.154 61830 typ host generation 0 ufrag 20JD network-id 2 network-cost 10 a=candidate:1955996700 1 tcp 1518280447 10.228.240.33 60286 typ host tcptype passive generation 0 ufrag 20JD network-id 1 a=candidate:1980673041 1 tcp 1518214911 192.168.0.154 60287 typ host tcptype passive generation 0 ufrag 20JD network-id 2 network-cost 10 a=candidate:1955996700 1 tcp 1518280447 10.228.240.33 60288 typ host tcptype passive generation 0 ufrag 20JD network-id 1 a=candidate:1980673041 1 tcp 1518214911 192.168.0.154 60289 typ host tcptype passive generation 0 ufrag 20JD network-id 2 network-cost 10 a=candidate:3116717653 1 udp 1685987071 80.98.2.199 61828 typ srflx raddr 192.168.0.154 rport 61828 generation 0 ufrag 20JD network-id 2 network-cost 10 a=candidate:3116717653 1 udp 1685987071 80.98.2.199 61830 typ srflx raddr 192.168.0.154 rport 61830 generation 0 ufrag 20JD network-id 2 network-cost 10 a=end-of-candidates
Answer message
v=0 o=rtcweb 1 1 IN IP4 127.0.0.1 s=- t=0 0 a=ice-lite m=audio 22948 RTP/SAVPF 111 110 c=IN IP4 199.87.123.94 a=ice-ufrag:l+UE a=ice-pwd:PAXI8kXVBo+N91F+8mGGgr5/ a=fingerprint:sha-256 FC:A8:9D:19:A1:0F:76:B5:65:56:B6:A4:8E:C3:2C:1E:F8:90:B7:BF:1B:08:A1:58:05:86:AC:78:E4:2D:A9:6A a=setup:passive a=sendrecv a=rtcp-mux a=rtcp:9 IN IP4 0.0.0.0 a=rtpmap:111 opus/48000/2 a=fmtp:111 minptime=10; useinbandfec=1 a=rtcp-fb:111 transport-cc a=rtpmap:110 telephone-event/48000 a=maxptime:60 a=candidate:0 1 UDP 2113667327 199.87.123.94 22948 typ host a=end-of-candidates a=ssrc:1192398718 cname:67be75c1-339e-4e48-ab65-5c5c6d2f65d7 a=ssrc:1192398718 msid:946e4825-0536-447f-82ec-962dd87fe724 3afca3af-565c-4dca-926a-29de8f0258f6 a=ssrc:1192398718 mslabel:946e4825-0536-447f-82ec-962dd87fe724 a=ssrc:1192398718 label:3afca3af-565c-4dca-926a-29de8f0258f6
Screenshots
![01](https://user-images.githubusercontent.com/77939189/150405321-e746db43-e012-445c-8428-2481629229e1.png)
![02](https://user-images.githubusercontent.com/77939189/150405349-de1e18e3-b2ba-4199-9d17-518e9f6624a0.png)
![03](https://user-images.githubusercontent.com/77939189/150405379-a4e7e79f-6c4a-4cb6-96b8-6f7e1144b095.png)
![04](https://user-images.githubusercontent.com/77939189/150405389-3ea9b2bc-4ed9-489b-a49b-552489431712.png)
![05](https://user-images.githubusercontent.com/77939189/150405397-fe0b43fe-c4e7-420b-82ea-d6a03daa2fff.png)
Questions
After reading my summary you can easily tell by now that I am not really familiar with WebRTC and SDP attributes. I have read all earlier issues related to this exception and if I understand correctly the problem is the incompatibility of the SDP offer and answer. My questions are: What can cause this exception? There is no matching codec or ICE candidate in the offer and answer? Or I just made simply a wrong implementation?
Environment
The text was updated successfully, but these errors were encountered: