test if peer is webrtc compatible
ralyodio opened this issue · 3 comments
ralyodio commented
I'm using this code to get peers:
dht.lookup(data.infohash, (err, peers) => {
data.peers = peers; // eg: 10
resolve(data);
});
Is there anyway to check the peers
to see if any support webrtc/webtorrent?
feross commented
The peers found in the DHT will always be ip:port
peers, never WebRTC peers. Technically, the client listening on the ip:port
could also support WebRTC, but there's no way to find that out.
ralyodio commented
Its not even possible to try connecting over webrtc somehow and see if it succeeds?
feross commented
No, an IP and port is not enough to connect over WebRTC. I suggest reading about how WebRTC works.