My attempt at setting up a basic video chat using webRTC has hit a roadblock. While everything functions smoothly on a local network, trying to establish an Internet connection results in termination of the connection.
I've implemented
iceServers: [{urls: 'stun:stun.l.google.com:19302'}]
, but it doesn't seem to resolve the issue.
chrome://webrtc-internals/
indicates that all candidates were successfully transferred, pauses for about 15 seconds, and then displays:
iceconnectionstatechange disconnected
iceconnectionstatechange(legacy) failed
Throughout those 15 seconds, peer.connectionState
remains connecting
before ultimately transitioning to failed
on both ends.
Apologies for not sharing the code here as it is extensive, but you can test it out at . I've added a lot of information to the console for debugging purposes, and you can also access chrome://webrtc-internals/
for more details.
Edit 1: I came across https://appr.tc and tried connecting via this platform. However, I encountered the same error message, leading me to believe that the setup is correct, and the issue may be related to firewall or NAT restrictions?
Edit 2: After some time, stun server error 701 appeared: https://i.sstatic.net/4QRI1.png
Edit3: Found a detailed webrtc log in Firefox:
[Log Details]
[A series of log entries showcasing ICE candidate pairing and fail states]
[Summary: All checks completed with 0 success and 1 failure]