I think serving video is a particularly interesting use of Webtorrent. I think it would be good if you could add this as a front end to basically make sites DDOS proof. So you host like a regular site, but with a JS front end that hosts the site P2P the more traffic there is.
I really dislike the monopoly YouTube has on online video, but other options or self-hosting can become really expensive due to bandwidth (especially if your video suddenly goes viral). I think P2P (over WebRTC, for browser compatibility) has potential for creating a solution.
Roughly:
* You have a Website with some <video>s you want to share hosted somewhere—doesn't matter if it's dynamic, static, hosted on a CDN or a VPS, as long as it imports a few scripts and embellishes the <video> tag with a few details.
* Base case: you want to publish a video, you host the video. That means you host a server at home that is running the hosting software (maybe WebTorrent based, maybe something custom). As high-speed fiber Internet becomes more common, hosting video from a home network becomes more feasible (unless ISPs decide to cock-block it).
* A signaling server establishes a P2P connection (WebRTC datachannels) between a visitor of your Website and your video-hosting home server.
* If you have a fast enough Internet connection (100+ Mbps) and low traffic, I don't see why the base case shouldn't work (other than network connectivity problems due to complicated NATs and such). If you have a surge of simultaneous traffic, those that came earlier can offload pressure on the home server by seeding the video chunks they have already downloaded. Theoretically, infinite scalability without bandwidth or hardware bottlenecks (but likely coordination woes in practice).
But there's more!
Say there's another person on the Web hosting their videos in the same way. If I like their video, I can re-host it on my own home server and let their signaling server know about it. Now there are two "persistent" video servers hosting the video that a visitor can download from. If I trust this person, I can choose to automatically re-host all their past and future videos.
Moderation isn't a problem, because you explicitly choose which videos to re-host, or because you re-host (future) videos of people you trust.
The more people re-host videos, the better their availability, download speed, and latency if hosts are geographically distributed.
Further ideas of pooling signaling servers and home servers into networks to enable other possible niceties (though likely with a more substantial moderation burden) ...
I've tried a really basic proof of concept of the base case (across a few countries on a mobile network!), and it worked!
Currently, I'm looking to talk with anyone who is interested in any of this :)
In 2020, I messed around with a PoC for what hosting and distributing Linux distros could look like using WebTorrent[1]. The protocol project as a whole has a lovely and brilliant design but has stayed mostly stagnant in recent years. There are only a couple of WebRTC-enabled torrent trackers that have remained active and stable.
I don't remember the web torrent issue numbers off the top of my head, but there are a number of long standing issues that seem blocked on webrtc limitations.
If we could say do peer discovery via Bluetooth, and open sockets directly from a browser page, we could in theory have local-first websites running in the browser, that does P2P connections straight between browsers.
> they cannot open bi-directional unordered connections between two browsers.
Last I checked, DataChannels were bidirectional
There is a Native Sockets spec draft that only Chrome implements;
"Direct Sockets API": https://developer.chrome.com/docs/iwa/direct-sockets :
> The Direct Sockets API addresses this limitation by enabling Isolated Web Apps (IWAs) to establish direct TCP and UDP connections without a relay server. With IWAs, thanks to additional security measures—such as strict Content Security Policy (CSP) and cross-origin isolation— this API can be safely exposed.
Though there's UPNP XML, it lacks auth for port forwarding permissions. There's also IPV6.
Similar: "Breaking the QR Limit: The Discovery of a Serverless WebRTC Protocol – Magarcia" https://news.ycombinator.com/item?id=46829296 re: Quick Share, Wi-Fi Direct, Wi-Fi Aware, BLE Beacons, BSSIDs and the Geolocation API
There are some nodes (desktop clients with UPNP, dedicated servers) that can accept browser connections. Those nodes could then help you exchange offers/answers to give you connections with the Webrtc-only ones, and those could facilitate offer/answer exchanges with their peers in turn.
It'd be dog-slow compared to the single-udp-packet-in, single-udp-packet-out philosophy of traditional mainline DHT, but I don't see why the idea couldn't work in principle.
I think a much bigger problem is content discovery and update distribution. You can't really do decentralized search because it'd very quickly get sybil-attacked to death. You'd always need some kind of centralized, trusted content index, but not necessarily one hosted on a centralized server. If you could have a reliable way to go from a pubkey to the latest hash signed by that pubkey in a decentralized way, + E.G. a Sqlite extension to get pages on-demand via WebTorrent, that would get you a long way towards solving the problem.
The elinks text-only browser has a "real" torrent client
The cool thing was it worked at the browser level using experimental libdweb support, though that has unfortunately since been abandoned. You could literally load URLs like wtp://tomjwatson.com/blog directly in your browser.
Pretty cool! Not sure what this offers over WebTorrent itself, but I was happy to learn about its existence.
I like the idea though.
Probably needs more testing and debugging.
https://metaversejs.github.io/peercompute/
it's a gpgpu decentralized heterogeneous hpc p2p compute platform that runs in the browser
Though the irony of being censored while talking about how CSA should be censored is very funny to me.
These pro-speech absolutists (who are usually libertarian) miss that NAP is clearly violated when any abuse is hosted/disseminated. Additionally while speech should never be censored.. everything must be permissible if all media is speech. You can have a society that censors multi-media but not the caption/description attached; other allowances (for other types of "speech") always leads to the most degenerate of people having a voice while everyone else is punished for calling them out.
Not only did it take > 5 seconds to load a page, images were progressively loaded as fast as two at a time over the next minute or so - if there were no errors during transfer!
https://github.com/RickCarlino/hazelhop
It works, though probably needs some cleanup and security review before being used seriously (thus no running public instance).
[0]: https://peerweb.lol/?orc=b549f37bb4519d1abd2952483610b8078e6...
I’m not sure what the value prop is over just using a torrent client?
Maybe when they’re less buggy they’ll become a thing.
I put the project on hiatus years ago but I'm starting it back up soon! My project is not vibe coded and has thus far been manually architected with a deep consideration for both user and site owner expectations in the web ecosystem.
Just using a torrent client means that you have to download the website locally with a torrent client, and then open it in your browser. Most people wouldn't do that.
Would it be the case for folks who don't have any idea what Lovable is.
Familiar UI is similar to what Tailwind or Bootstrap offers, do they do something different to keep it fresh?
Average internet users/consumers are likely used to the default Shopify checkout.
The Stripe or Shopify checkout is familiar, but it only became familiar because it was well designed and people wanted to keep using it.
Also when its obvious someone used an LLM, it bleeds into my overall opinion of the product whether the product is good or not. I assume less effort was put into the project, which is probably a fair assumption.
Grok almost never uses emojis.
Ask any modern (post-GPT-2) LLM about a random color/name/city repeatedly a few dozen times, and you'll see it's not that random. You can influence this with a prompt, obviously, but if the prompt stays the same each time, the output is always very similar despite the existence of thousands of valid alternatives. Which is the case for any vibecoded thing that doesn't specify the color palette, in particular.
This effect is largely responsible for slop (as in annoying stereotypes). It's fixable in principle, but there's pretty little research and I don't see big AI shops care enough.
https://github.com/Omodaka9375/peerweb
https://github.com/Omodaka9375/peerweb/releases/expanded_ass...
If the address is a hash perhaps it could contain a public key
Design decisions
dropclickpaste.com is for sale. kruhft.at.gmail.com
> XSS Protection - All HTML sanitized with DOMPurify > Malicious Code Removal - Dangerous tags and attributes filtered > Sandboxed Execution - Sites run in isolated iframe environment
I don't think that super makes sense. You probably just want the iframe sandbox and not remove all js. Or ideally put the torrent hash as the subdomain to use same origin policy.
Ultimately I guess the distributed web is felled by economics thus far.
But I have never had a successful experience with WebTorrent, presumably because it is less popular and I have never found a use-case where enough peers were sharing?
I liked BitTorrent Sync, but it was always closed source, and now it's part of something called Resilio.
The key difference is the approach: it uses a Service Worker as an embedded HTTP server in the browser. This means files are loaded on-demand rather than requiring full downloads upfront. The SW intercepts fetch requests and streams chunks directly from the torrent swarm.
Live demos using some PeerWeb demo sites:
- Chess: https://gate.distribyted.com/?tid=1e14b1ba7fcd03e5f165d53ed8...
- Functionality test page: https://gate.distribyted.com/?tid=90c020bd252639622a14895a0f...
Code: https://github.com/distribyted/gate
Caveat: This is a proof of concept, so stability varies and it works best on Chromium-based browsers.
This is meant to work with PeerWeb App which is more secure and stripped down torrent desktop client, that you can use to share your websites and host them through peerweb.lol. Still haven't released the dektop client but might do it.
Point of this is for everyone to host their content without needing servers, and as a great learning experience. Security is very big caviat here, so in no way is this final secure version.
elbci•1mo ago
dtj1123•1mo ago
elbci•1mo ago
dtj1123•1mo ago
sroerick•1w ago
One issue I've had with IPFS is that there's nothing baked into the protocol to maintain peer health, which really limits the ability to keep the swarm connected and healthy.
theendisney•1w ago
Some new ideas are needed in this space.
recursivegirth•1w ago
User's can publish their DNS + pub key to the append-only blockchain, signed with their private key.
Use a torrent file to connect to an initial tracker to download the blockchain.
Once the blockchain is downloaded, every computer would have a full copy of the DNS database and could use that for discoverability.
I have no experience with blockchains or building trackers, so maybe this is a dumb idea.
theendisney•1w ago
From what i've seen you need some minimum percentage of makeithappen-ers amoung those interested in a project.
It seems the guy running the extension just left. With minimum influence on the value.
https://addons.mozilla.org/en-US/firefox/addon/b-dns/
https://www.coinbase.com/en-nl/price/namecoin
soulofmischief•1w ago
dang•1w ago
logicallee•1w ago
https://news.ycombinator.com/item?id=46830158
https://news.ycombinator.com/item?id=46830183
toomuchtodo•1w ago
Bittorrent, in my experience, "just works," whether you're relying on a torrent server or a magnet link to join a swarm and retrieve data. So, this is an interesting experiment in the IPFS, torrent, filecoin distributed content space.
[1] https://ipfs.tech/
[2] https://news.ycombinator.com/item?id=29920271
[3] https://www.bittorrent.org/beps/bep_0046.html
amelius•1w ago
grumbel•1w ago
That means even distributing a piece of perfectly legal Open Source becomes illegal. Unlike a tarball or even a torrent where you can bundle content and license, IPFS allows addressing individual files or blocks, thus stripping the license from the content, which most licenses forbid. This does not even require an intentional action on the user, but happens automatically by partial content landing in your cache.