📜 ⬆️ ⬇️

The 9-kilobyte script will turn any browser from WebRTC into a distributed CDN node

A little more than two years ago I wrote a research article called The Dark Matter of the Internet . The main idea of ​​this article is to use the resources of millions of ordinary Internet users in order to remove most of the load from websites, just as participants in BitTorrent networks help each other download files. This could greatly reduce the cost of hosting, reduce the dependence of sites on advertising and paid services or donations. Then any attempts to implement such a "decentralized CDN" came up against the need to install special software as a separate application or browser extension.

But a couple of months ago, the first video call took place between the Firefox and Chrome browsers, made possible by the WebRTC technology. Together, these browsers have a market share of almost 60%, which means everything you need to become a node of a P2P network, most Internet users already have or will appear in the coming weeks (when full support for WebRTC will be included in the stable build of Firefox).

Startup PeerCDN is going to use new features to create a distributed CDN for static content, which can be used by simply including a small (9 kb) script in the page code. No plug-ins, add-ons and additional gestures are needed, everything happens transparently for the client. The creators promise to start the service in the coming weeks, but for now you can join the mailing list.
')



The principle of PeerCDN is practically no different from the work of the experimental add-on FireCoral, which I told you about two years ago, so I’ll just quote from an illustration from that article:

FireCoral intercepts HTTP requests, and if there is nothing suitable in the browser cache, it accesses the tracker (1). The tracker either informs (2) the addresses of peers that have the required file in the cache (3), or sends it to the source server, if the query has not been cached yet, or the version in the cache is expired (4). The authenticity of everything FireCoral downloaded from peers is certified by a digital signature provided by a trusted signature server (5). Having completed the processing of the request, FireCoral informs the tracker that it now also has a copy (6).

image



PeerCDN connects to peers via WebRTC, and is able to switch transparently for the user between booting from peers and from the server if peers have become unavailable. In addition, there is support for working with streaming video.

PeerCDN does not disclose details about its monetization strategy yet, apparently, the company intends to make money by providing its servers as trackers and certification and authorization centers. Naturally, this may cause webmaster and user concerns, because PeerCDN will focus on who is downloading which files and confirming their authenticity will also be in the hands of the company. On the other hand, such claims can be made of any CDN.

Another question to this technology is how users will react to the fact that files will be distributed from their computer. PeerCDN promises to take care of user browser resources and disable distributions when working via the mobile Internet or when the battery level is low. Perhaps sites should warn the user about the use of PeerCDN, just as they now warn about the use of cookies.

In any case, this is a very promising technology for sites with a lot of open public content, especially heavy multimedia. In fact, we are talking about the ability to create a dynamically scaling CDN for each site, which will work better and more stable than more visitors to the site. And almost free. And with the advent of such PeerCDN standalone solutions for mainstream server platforms that any webmaster can install on their own on their own website, all questions regarding possible surveillance and control over the distribution of content will disappear.

Source: https://habr.com/ru/post/174549/


All Articles