Secure Scuttlebutt - p2p offline social network

Scuttlebutt is a slang word used by American sailors to mean rumors and gossip. Node.js developer Dominic Tarr, who lives on a sailboat off the coast of New Zealand, used this word in the name p2p network, designed to exchange news and personal messages. Secure Scuttlebutt (SSB) allows you to share information using only occasional access to the Internet or even in its complete absence.

SSB has been running for several years. Social network features can be tested using two desktop applications ( Patchwork and Patchfoo ) and an Android application ( Manyverse ). There is ssb-git for geeks. Are you curious how offline-first p2p network works without ads and without registration? I ask for cat.



For the functioning of Secure Scuttlebutt, two computers connected to the local network are enough. SSB-based applications send broadcast UDP messages and can automatically find each other. Finding sites on the Internet is a bit more complicated, and we will return to this issue in a few paragraphs.

A user account is a linked list of all his entries (log). Each subsequent record contains the hash of the previous one and is signed by the user's private key. The public key is the user identifier. Deleting and editing entries is impossible neither by the author himself, nor by anyone else. The owner can add entries to the end of the log. Other users - read it.

Applications located on the same local network see each other and automatically request updates from neighbors in the magazines of interest to them. It doesn’t matter which node you download the update from, because You can verify the authenticity of each entry using the public key. During synchronization, no personal information is exchanged other than the public keys of the magazines you are interested in. As you switch between different WiFi / LAN networks (at home, in a cafe, at work), copies of your local logs will be automatically transferred to devices of other users who are close to you. It’s like word of mouth: Vasya told Masha, Masha - to Petya, and Petya - to Valentina. A significant difference from word of mouth is that when copying magazines, the information in them is not distorted.

“Being with someone in friends” here takes on a specific physical meaning: my friends keep a copy of my journal. The more friends I have, the more accessible my magazine is for others. The description of the puncture says that the Patchwork application synchronizes logs that are up to 3 steps away (friends of friends of friends) from you. In most cases, this allows you to read long discussions with many participants while offline.

A user’s journal can contain records of various types: public messages similar to those on the VK wall, private messages encrypted with the recipient’s public key, comments on other users ’posts, likes. This is an open list. Pictures and other voluminous files are not directly logged. Instead, a hash of the file is written to it, with the help of which this file can be requested separately from the log itself. The visibility of comments for the author of the original message is not guaranteed: if there is not a short path between your common friends between you, then most likely you will not see such comments. Thus, even if the military sleighs attempt to seize your post, then if these were not your friends or friends of friends of friends, you will not notice anything.

Secure Scuttlebutt is not the first p2p network or even the first p2p social network. The desire to communicate without intermediaries and leave the sphere of influence of large companies has existed for a long time, and it has several obvious reasons. Users are annoyed by the imposition of game rules by large players: few people want to see ads on their screen or be banned and wait a few days for a response from the support service. The uncontrolled collection of personal data and its transfer to third parties, which ultimately leads to the fact that this data is sometimes sold on the Internet, again and again reminds you of the need to build other ways of interaction where the user would get more control over his data. And he himself would be responsible for their distribution and preservation.

Well-known decentralized social networks such asDiaspora or Mastodon , and the Matrix protocol are not peer-to-peer, because they always have a client and server part. Instead of a common Facebook database, you can choose your “home” server on which your data will be posted, and this is a big step forward. However, the administrator of your “home” server still has many possibilities: he can share your data without your knowledge, delete or block your account. In addition, it may lose interest in server support and not warn you about it.

Secure Scuttlebutt also has intermediary nodes to facilitate synchronization (they are called "pubs"). However, the use of pubs is optional, and they themselves are interchangeable. If your usual site is not available to you, you can use others without losing anything, since you always have a full copy of all your data. The proxy does not store irreplaceable data. The pub, if you ask for it, will add you as a friend and, when connected, will update its copy of your journal. When your subscribers connect to it, they will be able to upload your new posts, even if you have already disconnected. In order for the pub to be friends with you, you must get an invite from the pub administrator. Most often, this can be done independently through a web-interface ( list of pubs) If you get a ban from all pub administrators, then your journal will be distributed as described earlier, i.e. only among those you meet in person. Transferring updates to a flash drive is also possible.

Although the network has been around for quite some time, there are few people in it. According to estimates André Staltz, Developer Android-application Manyverse , in June 2018 in its local database was around 7000 keys . For comparison, in Diaspora - more than 600 thousand , in Mastodon - about 1 million.



Instructions for beginners are here. The main steps: install the application, create a profile, get an invite on the pub website, copy this invite to the application. You can connect multiple pubs at the same time. You will need to be patient: the network is much slower than Facebook. The local cache (.ssb folder) will quickly grow to a few gigabytes. It is convenient to search for interesting posts by hash tags. You can start reading, for example, with Dominic Tarra (@ EMovhfIrFk4NihAKnRNhrfRaqIhBv1Wj8pTxJNgvCCY = .ed25519).

All images are from André Staltz's “An off-grid social network” article and his Twitter account .

Useful links:

[1] Official site

[2] Patchwork (application for Windows / Mac / Linux)

[3] Manyverse(Android app)

[4] ssb-git

[5] Protocol Description ("Scuttlebutt Protocol Guide - How Scuttlebutt peers find and talk to each other")

Also popular now: