Configuration reference¶
The node reads a TOML file, by default /home/unseenet/node.toml when
installed with the script. After changing it:
sudo systemctl restart unseenet-node
Changing what the node carries. When you change what decides which
posts the node takes from its peers - new_groups, trusted_owners,
carries, excludes, profiles, avatars, sites, [blobs] or a peer's
accept - the node notices at the next start. It forgets the posts it
refused under the old setting, catches up with its peers again from the
start of retention, and fetches the files of posts it already holds if
it now carries them. The start says so in one line. Nothing is needed by
hand; what the node already has is not fetched twice.
Example¶
[node]
name = "mynode"
min_pow = 18
min_ripe = 0
retention_days = 90
new_groups = "accept"
trusted_owners = []
require_peer_auth = true
[[peer]]
name = "friend"
address = "abcdef...xyz.onion:119"
key = "ed25519:..."
groups = "*"
[node]¶
| Key | Default | Meaning |
|---|---|---|
name |
"unseenet" (the installer uses the hostname) |
The node's name, shown to clients. With old password peering it is also the user name, so it must match the name the other side has for you. |
min_pow |
18 |
Minimum postage in bits for posts this node accepts. Each extra bit doubles the cost. Group owners can require more for their groups. |
min_ripe |
0 |
The lowest key ripening level (0-4) this node accepts, or "-" for none. A new key reaches level 0 after a few minutes of computing on its owner's machine, so throwaway keys cost something. Riper keys pay less postage. Needs chiavdf (installed with Unseenet on Linux, Windows and Apple Silicon). |
retention_days |
90 |
How long posts are kept. A group's own retention is used if it is shorter. Expired posts are removed once an hour. |
max_size |
65536 |
Largest post in bytes. Must be between 32768 and 65536. |
carries |
["*"] |
The hierarchies this node carries, such as ["alt.*", "dk.*"], see below. The network's own groups are always carried. |
announce |
true |
Announce the node in the network, so people can find it, see below. |
ripen_to |
1 |
How far the node ripens its own key before it announces itself. |
auto_peers |
3 |
Also pull from this many nodes the node finds announced, chosen at random and changed daily, so it gets the network's posts without agreed peers. 0: only the peers below. See Peers found by themselves. |
welcome_new |
true |
Besides those, also pull from one node that announced itself for the first time in the last week, so new nodes are part of the network at once. |
spread |
"auto" |
Send what this node's own readers post to the announced nodes it pulls from: "auto" when no [[peer]] takes pushes from it (a new node), "on", "off". |
pow_defense |
true |
Turn on Tor's proof-of-work defence for the node's onion service: under a flood of connections, Tor asks new clients for a small proof of work and serves those who pay it first, so the node stays reachable (UN-RFC 0005). Needs Tor 0.4.9.2 or newer; with an older Tor the node runs without it and the monitor says so. |
test_addresses |
false |
For a test network: allow peers at a public address over plain TCP, which hides nothing. Not needed for your own nodes on your own network. |
new_groups |
"accept" |
Which new groups this node carries, see below. |
excludes |
"" |
Groups this node does not carry by choice, as a wildmat, see below. |
trusted_owners |
[] |
Owner keys ("ed25519:...") whose new groups are accepted when new_groups = "trusted". |
pull_interval |
3600 |
Seconds between catch-up pulls from each peer. |
honour_blocks |
false |
Refuse posts by identities that a hierarchy's maintainer has blocked (see below). |
profiles |
"accept" |
Carry identities' public profiles (profile@...), see below. "refuse" to leave them out. |
avatars |
"refuse" |
Carry identities' pictures (avatar@...). Off until you turn it on. |
emoji |
"refuse" |
Carry groups' own emoji (<group>.emoji@..., UN-RFC 0056): small pictures. Off until you turn it on; the installer follows your answer for pictures. |
sites |
"refuse" |
Carry sites: channels shown as pages, kept until their owner changes them (UN-RFC 0035). Off until you turn it on. |
require_peer_auth |
true |
Only configured peers that authenticate can push posts to this node. Clients can always post. Set false only for testing. |
Profiles and pictures¶
An identity can publish a short public profile - a few lines about
itself, the languages it writes, links to other accounts - and a small
picture (UN-RFC 0022). Each lives in a tiny
group of its own that follows from the identity's key: profile@<fp>
and avatar@<fp>. They hold one signed manifest each and no posts.
- Profiles are text, at most 8 KiB. Nodes carry them by default,
also when
new_groupsistrustedormanual, since they are not groups anybody joins. Setprofiles = "refuse"to leave them out. - Pictures are images (at most 8 KiB, 128 × 128 pixels). No node
should carry images it has not chosen to, so
avatarsis"refuse"until you set it to"accept". - Group emoji are up to 16 pictures of 32 × 32 pixels (at most 1 KiB
each) that a group's owner gives the group, in a data group of their
own,
<group>.emoji@<fp>. As for pictures,emojiis"refuse"until you set it to"accept"; refusing them never refuses the group.
Refusal lists and
--refuse-blob cover pictures and group emoji as they cover files.
Both expire two years after their owner's client last renewed them, and the node then removes them by itself (UN-RFC 0029). Your node information says what you chose.
honour_blocks: maintainers' blocks¶
A hierarchy's maintainer (for example whoever runs dk.*) can block an
identity in its whole hierarchy, with a public reason
(UN-RFC 0018 section 5.4) - say someone who
posts threats in group after group. With honour_blocks = true your node
refuses new posts by blocked identities in the groups under that
hierarchy. Readers' clients hide those posts anyway (they can choose to
see them); this setting decides whether your node carries them at all.
It is off by default: whose blocks you follow is your decision as an operator. The node reads the blocks from the lists it carries (the project's root list and the maintainers' lists) and says in its node information whether it honours them.
[[follow_reports]]: spam reports¶
Anyone can publish spam reports: signed lists of posts and identities,
each with a reason, in a group of their own (reports@<fp>,
UN-RFC 0045). Nobody has to listen. Your node
follows nobody unless you name an issuer here, and for each one you
choose what it does:
[[follow_reports]]
issuer = "ed25519:..." # the issuer's key
posts = "hide" # "hide": kept, not served, not forwarded - or "delete"
keys = "surcharge" # "refuse" new posts, "surcharge" (+6 bits postage), or "ignore"
The node reads the issuer's reports from its reports@ group, which it
carries like other key-bound groups, and applies them as they arrive -
also to posts that come later. When the issuer withdraws a report, a
hidden post is served again. A reported identity can still renew its own
key-bound groups (inbox, profile, feed), and nothing an issuer reports
ever makes posting cheaper for anyone.
Readers' clients decide for themselves which issuers they follow, and
show a post as "Hidden by ... : spam" rather than dropping it. This
setting decides only what your node carries and passes on. Your node
information lists the issuers you follow (policy.report_issuers).
carries: the hierarchies you carry¶
[node]
carries = ["alt.*", "dk.*", "!dk.politik.*"]
A node does not have to carry every group (UN-RFC 0055).
List the hierarchies you want, as patterns over group names: * matches
anything, a pattern starting with ! leaves out, and the last pattern that
matches decides. ["*"], the default, is everything. A node for one cause
might carry only ["palaestina.*"]; an association only ["forening.*"].
Whatever the list says, every node carries the network's own groups:
the lists of nodes, hierarchies and names, releases and announcements, and the
other groups of unseenet.* that the hierarchy's maintainer endorses. They are
small and text only. Without them, a node or a group of nodes could hide which
nodes carry what. They cannot be left out with excludes or dropped. A group
somebody names unseenet.something without that endorsement is an ordinary
group and follows your list.
Profiles, pictures and other groups that belong to one key (profile@...,
inbox@...) follow their own settings, not this list, and so do
local groups.
The node says what it carries in its node information, so clients and peers can see it. A peer sends you only the groups you both carry, and you send a peer only what it carries; it learns that when it connects, and again daily.
announce: being found¶
A node tells the network where it is and what it carries: its onion address, its
name and its carries, in the group unseenet.nodes.announce that every node
carries (UN-RFC 0055 section 5). It signs this with its
node key, so nobody else can announce in its name, and nobody has to approve it.
It announces itself when it starts, when what it says changes, and every few
weeks. Clients check a node before they use it.
Before its first announcement the node ripens its key
(UN-RFC 0025), like any key that posts: a few minutes of
one core for level 0, a few hours for level 1 (ripen_to). It runs in the
background at low priority, also on a Raspberry Pi, and only once.
A node only for a few friends can stay unannounced: announce = false. It still
carries the network's own groups.
One key per node. Never run two nodes with the same node key (a copied data folder): their announcements would hide each other, and the network would count them as one node.
new_groups: which groups the node carries¶
| Value | Behaviour |
|---|---|
accept |
Every new group is carried. Good for small private networks among friends. |
trusted |
Only groups whose owner key is in trusted_owners. Good for a public node where you want to know who creates groups. |
manual |
No new groups are accepted. (A tool to add groups by hand is not written yet.) |
This only affects new groups. Groups the node already carries keep working, and posts in them are checked against the group's own posting settings (who may post, postage, bans) - never against its charter, which no machine enforces.
excludes: groups you leave out¶
[node]
excludes = "alt.binaries.*,!alt.binaries.test*"
Posts and new groups matching excludes are refused, from clients and
peers alike. The node tells clients what it leaves out (users see it
under About this node), together with every group you have
dropped.
A listed node must carry what most listed nodes carry, except what it
excludes (UN-RFC 0021). excludes is how you
stay listed and still leave out something you will not or may not carry
where your node runs. For whole hierarchies, use carries instead. The
network's own groups (see carries) cannot be excluded.
[limits]¶
[limits]
max_clients = "auto" # or a number
max_clients: how many client connections the node keeps open at
once. Through Tor every client looks the same, so a node cannot limit
per visitor; this is a ceiling, so that a misbehaving web entrance or a
script cannot open more than the machine can carry. "auto" (the default)
is what memory and open files allow - about 50 KB of memory and two open
files per connection - which is tens of thousands on a small VM. When the
node is full, a new client gets 400 too many connections, try another
node and tries elsewhere; peers that authenticate are never refused and
do not count. The monitor shows the limit and how many were turned away.
The systemd unit and the Docker Compose file raise the open-files limit
to 65536 for this.
[blobs]¶
Pictures and small files in posts (UN-RFC 0027).
Off unless enabled = true; the installer asks
(why).
[blobs]
enabled = true
max_size = 1048576 # largest file, 1-4 MiB
retention_days = 30 # files go after this, the post stays
encrypted = false # also files of closed groups and private posts
groups = "*" # which groups, a wildmat
daily_per_key = 33554432 # 32 MiB per author key per day
daily_per_group = 268435456 # 256 MiB per group per day
A file goes when no post on the node references it any more (expired,
withdrawn, edited), or after retention_days, except files of pinned
posts. Over a daily limit, your own users get 441 quota; posts from
peers come in without their files.
Refusing a file. unseenet-node --data ~/node-data --refuse-blob
blob1:... --reason "..." deletes it, and the node never takes, fetches
or serves it again; the post that references it stays, and readers see
that the file is not available. A running node follows at once.
Refusal lists are set in [refusals].
The monitor shows how many files the node keeps, how much they take, today's uploads and how many are refused.
[refusals]: refusal lists for every picture¶
Refusal lists (UN-RFC 0027 section 7.3) name
pictures and files by their ID, so a node can refuse what someone it trusts
has found. They cover everything your node carries that is a picture or a
file: files in posts, profile pictures and groups' emoji - also when the
node carries no files ([blobs] off).
[refusals]
keys = ["ed25519:..."] # follow refusal lists by these keys only
groups = "*" # ... posted in groups matching this wildmat
A list is a post with Content-Type: application/x-unseenet-blob-refusals
and the body {"v":1,"blobs":["blob1:..."],"reason":"..."}, signed by one of
keys. Nobody can make your node follow a list; none is followed by
default. Your node information says whether you follow any. Lists cannot
name files of closed groups and private posts: those are encrypted.
refusal_keys and refusal_groups under [blobs] still work, as before.
[operator]¶
Who runs the node and how to reach them (UN-RFC 0011). Clients show it when the user presses O. All keys are optional.
| Key | Meaning |
|---|---|
key |
Your identity key (ed25519:...) as operator |
contact |
Group ID of your contact inbox, see Operations |
description |
A few words about the node |
logging |
What the node logs (shown to users) |
notify |
A command run when the contact inbox gets new messages - see below |
[operator]
key = "ed25519:det5dxev..."
contact = "operator@ph5fc5hop5232qsz"
description = "Andreas' test node in Denmark"
notify = "/usr/local/bin/tell-me"
Knowing when someone writes. The node cannot read your contact inbox - that
is the point of it - but it counts the messages. unseenet-monitor shows how
many there are and how many are new (C marks them seen once you have read
them in your client), and unseenet-node status warns about new ones. With
notify, the node runs your command each time new messages arrive: without a
shell, with UNSEENET_CONTACT_NEW, UNSEENET_CONTACT_MESSAGES and
UNSEENET_NODE in its environment and nothing of the messages themselves - so
you can send it on to ntfy, Home Assistant, e-mail or whatever you use:
#!/bin/sh
curl -s -d "$UNSEENET_CONTACT_NEW new on $UNSEENET_NODE" https://ntfy.sh/your-topic
[[peer]]¶
One section per peer. See Peering.
| Key | Required | Meaning |
|---|---|---|
name |
yes | Your label for the peer, used in the logs. (With a password: must equal the name in the peer's own [node] section.) |
address |
yes | The peer's onion address, onion:xyz.onion or just xyz.onion (port 119 unless you add one, xyz.onion:1119). Your own nodes on the same machine or network can peer over plain TCP, host:port (for example node2:119 or 192.168.1.20:119), when you give the peer's key; see Several nodes on your own network. A public address over plain TCP needs test_addresses = true in [node], for test networks only. |
key |
yes, for new peerings | The peer's node key, ed25519:... (UN-RFC 0016). Used to accept the peer logging in to you, and to check that you reached the right node. |
groups |
no, "*" |
Which groups to send to this peer, as a wildmat (see below). "" sends nothing. |
pull |
no, "*" |
Which groups to catch up on from this peer. "" pulls nothing. |
accept |
no, "*" |
Which groups to take from this peer, pushed or pulled. Posts in other groups are refused. See Choosing what to share. |
password |
no | Old shared-secret login, ignored when key is set. See Peering. |
Wildmats¶
Group selections use the classic Usenet wildmat syntax: comma-separated
patterns with * and ?, where ! excludes. The last matching pattern
wins.
| Pattern | Sends |
|---|---|
* |
everything |
dk.*,unseenet* |
groups starting with dk. or unseenet |
*,!alt.* |
everything except alt.* |
Patterns are matched against the full group ID (dk.snak@ab3k5x7q...),
so dk.snak* matches every dk.snak, whoever owns it. To match one
specific group, use its full ID.
Several nodes on your own network¶
Nodes on the same machine or home network - containers in one Docker
setup, a node on your NAS and one on a Raspberry Pi - can peer directly,
without Tor. Give each the other's address on your network and its node
key (unseenet-node --show-key on that node):
[[peer]]
name = "node2"
address = "node2:119" # or 192.168.1.20:119
key = "ed25519:..." # node2's node key
The key is required: it is how the node knows it is talking to your other machine. The connection itself is not encrypted, but articles are signed and closed groups are encrypted anyway. Such addresses are never announced or listed; to the rest of the network each node is still its onion address (UN-RFC 0064 section 2.3).
Peers found by themselves¶
Besides the [[peer]] entries, a node with Tor pulls from a few nodes that
announce themselves in the network (auto_peers, 3 by default). It checks
first that each answers with the key it announced, picks new ones every day
or when one stops answering, and checks everything it pulls like any other
article. Those nodes see this node's announcement and pull from it too, so a
new node gets the network's posts, and passes its own on, without anybody
setting up a peer.
A new node does not wait to be found. Until it has a [[peer]] that takes
pushes from it, it sends what its own readers post - and its own
announcement - straight to the nodes it pulls from, which pass it on
(spread). And every node keeps one place for a node that announced itself
for the first time in the last week (welcome_new), so a new node is pulled
from by others as soon as its announcement arrives. Agreed peers are still worth having: they push new posts
at once instead of within the hour, and they are kept whatever happens to
the announcements (UN-RFC 0055 section 5.5).