
Localhosting with Yggdrasil
I used to think of the internet as an ocean. Posting something was like adding a drop to it: it became part of the whole ocean straight away, which brought up images of eternity, life and death.
以下正文同步自 Hacker News 最新,版权归原站所有,已转换为易读排版。
Ipv6
Mesh Networks
Peter Retief
2 min read·
19 hours ago
--
I used to think of the internet as an ocean. Posting something was like adding a drop to it: it became part of the whole ocean straight away, which brought up images of eternity, life and death.
It has since become banal, a corporate and political playground where the drops are a commodity.
In the spirit of what the internet could have been, I designed yggstore, a locally hosted mesh network built on Yggdrasil. In Yggdrasil’s own words:
▎ “Yggdrasil is a new experimental compact routing scheme. It is designed to be a future-proof and decentralised alternative to the structured routing protocols commonly used today on the Internet, as well as an enabling technology for future large-scale mesh networks.”
You can probably see where this is going.
Enter Reed-Solomon. In a nutshell, Reed-Solomon is an algorithm that lets your data survive even when parts of it are lost.
yggstore splits each file into 4 MiB chunks and encrypts each chunk with AES-256-GCM, using one random key per file and a fresh nonce per chunk. It then uses Reed-Solomon to turn each chunk into data and parity shards. How many of each depends on how many machines are online, and from four machines up, no machine holds two shards of the same chunk. If only one machine is online, the upload is refused, because the file couldn’t survive losing it.
Each node in yggstore can run its own email, web and file server, with pub/sub messaging built in. A node can be as small as a Raspberry Pi 3 or as big as a rack-mounted server.
If your node goes down, your work is already spread across the network, so your email, websites and files stay available.
There’s no reason a single network couldn’t take in millions of nodes. In fact, that would make it even more effective.
I’ve put a few links below if you want more information. It’s all open source. Have fun!
正文由 探How 从来源站点 RSS 同步,内容未经改写;遇到排版缺失或需要图片、视频时请以原文为准。