Hacker News new | past | comments | ask | show | jobs | submit login

> ...it uses WebRTC to make the direct peer connections. This allows us to make use of WebRTC's NAT traversal tricks, as well as the fact that it can be used in browsers.

But I'm assuming it can't break through all NAT routers, right? A good portion of people still won't be able to use this?

A service usable by everyone would require STUN and TURN servers to be set up, no?

Or has WebRTC made advances I'm unaware of?




> But I'm assuming it can't break through all NAT routers, right? A good portion of people still won't be able to use this?

> A service usable by everyone would require STUN and TURN servers to be set up, no?

Anecdata, of course, but I haven't been able to reliably use any of these WebRTC based file transfer services (file.pizza, instant.io, etc etc). Testing mostly between two computers on the same subnet. Sometimes they work for a little while, at surprisingly low speeds (for two computers connected to the same wireless access point), sometimes I can let them sit for an hour and never get a connection. I've learned to not even bother trying them, it just wastes time.

That said, magic-wormhole (the original) works fine between the same devices, so maybe I'll see if something is somehow different about this implementation.

Edit: ah yes, this service hangs indefinitely on "connecting". You love to see it. (Firefox on Linux - firewall disabled specifically for this test - and Safari on macOS)

Edit: seems to be working in Chrome (Linux) to Firefox (Android). Not sure what the difference is.


Also didn't work for me on Firefox/Linux, between 2 tabs.


Hmm, maybe this is a classic "didn't bother testing on Firefox" situation. I wonder if anyone on a different OS can confirm.


I developed it mainly on Firefox on macOS. I'd love to figure out why it didn't work for you. Do you get anything on about:webrtc while trying to connect?


Thanks for the reply. I did the following for you:

1. Opened about:webrtc, clicked "start debugging".

2. Opened a WebWormhole on one tab.

3. Copy / pasted the code into WebWormhole on another tab. Got something like "invalid key".

4. Try again steps two and three. Got endless "connecting" message this time.

5. Stop debugging. No log file /tmp/WebRTC.log was created, so I clicked "save page". Used sed to replace my public IP address with x.x.x.x and uploaded here for you:

https://ipfs.io/ipfs/QmTM1ZSRk1xqfMd2FF23YzWxHpqjJ2B6kGFQqPd...

I hope this gives you enough information to fix the problem. I'd like to be able to use these tools too. I suppose it could be addon related, but another user confirmed the problem for Firefox / Linux. It would be useful to be able to detect various problems and report them to the user instead of hanging on "connecting".


This uses STUN servers to help it poke through NATs. (That's what I mean by "WebRTC's NAT traversal tricks")

There's no TURN server set for this, but it shouldn't be hard to add one. There are NATs where you'd need one to relay all the traffic, but these seem to be relatively rare nowadays. If anyone has any actual statistics on these I'd appreciate it!


" but these seem to be relatively rare nowadays "

AT&T 5G uses Symmetric NAT. It's not rare if you have an iPhone or iPad with cellular. No way to do P2P without relaying traffic unless you want to "guess" the randomized port number, and, on that front, there are NAT-device-aware algorithms that can make that process faster.

We were promised IPv6 will make NAT's not necessary but I believe service providers use NATs not simply to conserve the IPv4 space but to actively discourage using the service to host your own servers.


This man told the truth!

They are zealously pushing the "ever increasing speeds" of questionable benefit for the user - what for? So that commuters could watch 8k 120fps video while on a bus? Or rather to gather all kind of sensor data in real-time, audio and video included, from their human oil wells? To strip off people's clothes with millimetre wave imaging?

But making it easy for people to run their own home/mobile servers, share and cooperate without govporate oversight is clearly not on their agenda.


It's amazing what would be possible if NAT wasn't a thing. We will get there. Someday.


We are going backward. Newer 5G and fiber deployments where I live offer only IPv4 with carrier grade NAT. No IPv6, and no real IP unless you ask for one. (Not sure how long they will offer that to non-business subscribers.)


Which one? Which STUN server are you using?




The website uses Google's.

On command line it's an option and Google's is default. I'd like to make the signalling server also a STUN server at some point.


Oh that's interesting... I had no idea there were publicly available STUN servers like that.

But way back in 2014 a Google employee does seem to have confirmed it's free to use, but comes without guarantees.

[1] https://groups.google.com/d/msg/discuss-webrtc/shcPIaPxwo8/F...


I don't have any hard numbers, but I have heard ~85% ICE success rate with out TURN. But you are right, in some cases WebRTC will fail without TURN. Just no one wants to pay to run those servers :)

I would love to see TCP hole punching in ICE, but it sounds like it is super hard to get right.

Consumer internet does a lot better, lots of those failures come from Government/Military/Medical I bet.


You always need a at least a STUN server and in my experience that 85% isn't remotely true. For example STUN-only never worked from mobile internet (only tested some german providers).


> Just no one wants to pay to run those servers :)

No, it's the users that don't want their (meta)data inspected by a random third party in transit. This is why I don't use filepizza


how would TCP hole punching even work? TCP has state and a handshake. UDP doesn't.


UPnP can be used to setup port forwarding if the NAT gateway is configured correctly.


sure. I think it's a bit different though. upnp is like some remote control of your fw.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: