libp2p / rust-libp2p

The Rust Implementation of the libp2p networking stack.
https://libp2p.io
MIT License
4.51k stars 933 forks source link

bug(webrtc): Chrome data-channels not closing #4333

Open Marcel-G opened 1 year ago

Marcel-G commented 1 year ago

Summary

When connecting a js-libp2p (browser) peer and rust-libp2p peer via webrtc, data channels are no properly closing. The first reason for that is js-libp2p never closes them to begin with. That is being addressed here: https://github.com/libp2p/js-libp2p/pull/1976

The next issue is that the rust-libp2p WebRTC implementation webrtc-rs doesn't properly respond to the browsers stream reset, leaving the browser in a closing state.

And in case of switching to str0m https://github.com/libp2p/rust-libp2p/issues/3659, it also has the same issue:

Possible Solution

I am opening this issue for visibility, and to possibly get some support with the PR reviews on these repositories. This can be closed when bumping the dependency version.

Would you like to work on fixing this bug?

Yes

mxinden commented 1 year ago

Much appreciate the thorough work @Marcel-G. Thank you.

I subscribed to the relevant open issues and pull requests. Please ping me on those in case I can be helpful.