Live data from Hacker News

Snapdrop – AirDrop equivalent through a web browser using WebRTC

snapdrop.net

21–30 of 155 posts

Re: Snapdrop – AirDrop equivalent through a web browser using WebRTC

#23
I am working on an open source framework which connects nodes for collaboration and p2p transfer. I started off with WebRTC at the core but have since made it optional transport due to lack of portability. Snapdrop is amazing but if you give up on WebRTC you can use QR code for discovery and transfer files even when not on the same network.

Re: Snapdrop – AirDrop equivalent through a web browser using WebRTC

#24
post #17
post #14

As a practical matter, I find Signal's "Note to Self" extremely useful for private across-devices sharing.

Yup. I have been using it a lot. Didn't realize it even exited until I installed the desktop client and it showed up in contacts. They need some good PR on that feature.

Telegram has similar "Saved Messages" feature.

Re: Snapdrop – AirDrop equivalent through a web browser using WebRTC

#25

how was device discovery implemented?

Simply by grouping clients into rooms by their public IP.

> You can be discovered by everyone on this network

Assumption here being that the devices on the same network are all NAT'd behind the same public IP, which usually holds true.

See the server code for designating rooms & peers: https://github.com/RobinLinus/snapdrop/blob/master/server/in...

Can also test that there is no "discovery" beyond public IP grouping by turning off wifi on your mobile and joining from mobile network.

Re: Snapdrop – AirDrop equivalent through a web browser using WebRTC

#27
post #9
post #8

Earlier quoted context omitted.

this is 100% the thing apple does that google absolutely refuses to de-intermediate themselves out of. apple allows direct bluetooth discovery, google 100% insists on closed proprietary "android nearby" systems to find local devices. neither release protocols or standards to interoperate on.

Why can't I Airdrop from my phone to my MacMini thats connected via ethernet cable. They are on the same network, and verified with other tools, but AirDrop has to be done over wifi for what reason?

Short answer is - Airdrop is a protocol for setting up ad-hoc wifi networks via Bluetooth LE. If it went over ethernet it wouldn't be airdrop.

Long answer:

Airdrop does discovery via bluetooth. To send a file, the two devices connect via bluetooth to negotiate the details of a new ad-hoc wifi connection, which they then create, connect to, and use for the transfer.

The discovery does not rely on a shared network, and once connected, the devices never 'discuss' whether they already share a network, so it's WIFI or nothing.

This gives some security guarantees that wouldn't exist otherwise. EG: Airdrop won't go through Starbucks' WIFI, even if both the sender & receiver are connected to it. Honestly I'm not sure how important those guarantees are -- but they're there.

I don't think there's a fundamental barrier stopping Apple from:

1. Having devices advertise an 'airdrop-box' through Bonjour as well as though bluetooth LE,

2. Including these entires in the Airdrop UI

3. De-duping entries where it figures out that a network device is the same as a bluetooth device.

4. Running same-network transfers through SMB rather than using [what they currently call] Airdrop to negotiate an ad-hoc WIFI network.

...but they haven't done so.

Re: Snapdrop – AirDrop equivalent through a web browser using WebRTC

#29
This looks great!

Small nitpick about the wording of this:

"Notifications permission has been blocked as the user has dismissed the permission prompt several times. This can be reset in Page Info which can be accessed by clicking the lock icon next to the URL."

I have Safari set to not allow websites to ask for notification privileges at all and did not see a single prompt. And I don't think you can toggle it from the lock icon.

Post reply on HN