「GNUnet」の版間の差分

提供: ArchWiki
ナビゲーションに移動 検索に移動
198行目: 198行目:
 
}}
 
}}
   
  +
== アプリのエコシステム ==
== App ecosystem ==
 
   
 
=== GNUnet GTK ===
 
=== GNUnet GTK ===
   
  +
GNUnet GTK は、GNUnet フレームワーク用のグラフィカルインターフェイスのコレクションです。以下の [[GTK]] アプリケーションが同梱されています。
GNUnet GTK is a collection of graphical interfaces for the GNUnet framework. It ships the following [[GTK]] applications:
 
   
 
* {{ic|gnunet-conversation-gtk}}
 
* {{ic|gnunet-conversation-gtk}}
211行目: 211行目:
 
* {{ic|gnunet-statistics-gtk}}
 
* {{ic|gnunet-statistics-gtk}}
   
To install GNUnet GTK download the {{AUR|gnunet-gtk}} package.
+
GNUnet GTK をインストールするには、{{AUR|gnunet-gtk}} パッケージをダウンロードします。
   
=== Messenger GTK ===
+
=== GTK メッセンジャー ===
   
  +
現在、GNUnet ネットワーク上でチャットするためのいくつかのグラフィカルユーザーインターフェイスが開発されています。そのうちの 1 つは、モバイル対応の [[GTK]] である '''Messenger GTK''' ({{AUR|messenger-gtk}}、または開発バージョンの場合は {{AUR|messenger-gtk-git}}) です。コマンドラインを介したチャットについては、'''Messenger CLI''' (開発バージョンの場合は {{AUR|messenger-cli}} または {{AUR|messenger-cli-git}}) を参照してください。
Currently several graphical user interfaces for chatting on the GNUnet network are being developed. One of these is '''Messenger GTK''' ({{AUR|messenger-gtk}}, or {{AUR|messenger-gtk-git}} for the development version), a mobile-friendly [[GTK]] graphical user interface for chatting with GNUnet users. For chatting via command line, see '''Messenger CLI''' ({{AUR|messenger-cli}} or {{AUR|messenger-cli-git}} for the development version).
 
   
=== Web User Interface ===
+
=== Web ユーザーインターフェース ===
   
A Web interface for GNUnet exists and is available as {{AUR|gnunet-webui-git}}.
+
GNUnet Web インターフェースが存在し、{{AUR|gnunet-webui-git}} として入手できます。
   
 
=== re:claimID ===
 
=== re:claimID ===
   
  +
[https://gnunet.org/en/reclaim/index.html re:claimID] は、GNU ネーム システム上に構築された分散型アイデンティティプロバイダー (IdP) サービスです。これにより、ユーザーは標準化されたプロトコル (OpenID Connect) を使用して Web サイトと個人情報を安全に共有できます。
[https://gnunet.org/en/reclaim/index.html re:claimID] is a decentralized Identity Provider (IdP) service built on top of the GNU Name System. It allows users to securely share personal information with websites using standardized protocols (OpenID Connect).
 
   
For users ''re:claimID'' offers [https://addons.mozilla.org/addon/reclaimid/ an extension for Firefox] and [https://chrome.google.com/webstore/detail/reclaimid/jiogompmdejcnacmlnjhnaicgkefcfll an extension for Chromium] for managing ''re:claimID'' identities in the web browser (the {{AUR|gnunet}} package needs to be installed).
+
ユーザー向けに ''re:claimID'' [https://addons.mozilla.org/addon/reclaimid/ Firefox の拡張機能] [https://chrome.google.com/webstore/detail/reclaimid/jiogompmdejcnacmlnjhnaicgkefcfll 拡張機能] を提供します。 Chromium の拡張機能] Web ブラウザで ''re:claimID'' ID を管理するための拡張機能 ({{AUR|gnunet}} パッケージをインストールする必要があります)
   
  +
拡張機能をインストールした後、https://ui.reclaim/ にアクセスして、ローカルの ''re:claimID'' インスタンスに新しい ID を追加し、それにいくつかの属性を追加できるようになります (拡張機能がないとリンクは機能しません) インストールされています。
After having installed the extension it will be possible to add a new identity to the local ''re:claimID'' instance and add some attributes to it by visiting https://ui.reclaim/ (the link will not work without the extension installed).
 
   
For more information, please refer to [https://gnunet.org/en/reclaim/users.html the manual].
+
詳細については、[https://gnunet.org/en/reclaim/users.html マニュアル] を参照してください。
   
 
=== GNU Taler ===
 
=== GNU Taler ===
   
  +
GNU Taler は、GNUnet 上に構築されたマイクロトランザクションおよび電子決済システムです。他の分散型決済システムとは異なり、Taler はブロックチェーンに基づいておらず、代わりにブラインド署名に基づいています。
GNU Taler is a microtransaction and electronic payment system built on top of GNUnet. Differently than other distributed payment systems Taler is not based on a blockchain, but on blind signatures instead.
 
   
For more information please consult [https://taler.net/en/docs.html the official documentation]. See also packages {{AUR|sync}}, {{AUR|taler-exchange}}, {{AUR|taler-mdb}}, {{AUR|taler-merchant}} and {{AUR|taler-twister}}.
+
詳細については、[https://taler.net/en/docs.html 公式ドキュメント] を参照してください。パッケージ {{AUR|sync}}{{AUR|taler-exchange}}{{AUR|taler-mdb}}{{AUR|taler-merchant}}、および {{AUR|taler-twister}} も参照してください。
   
 
=== GNU Anastasis ===
 
=== GNU Anastasis ===
   
[https://www.gnu.org/software/anastasis/ GNU Anastasis] is a protocol and implementation that allows users to securely deposit core secrets with an open set of escrow providers and to recover these secrets if their original copies are lost. Anastasis is available on AUR ({{AUR|anastasis}} and {{AUR|anastasis-gtk}}). For more information please consult https://www.gnu.org/software/anastasis/ and https://anastasis.lu/.
+
[https://www.gnu.org/software/anastasis/GNU Anastasis] は、ユーザーがオープンセットのエスクロープロバイダーにコア シークレットを安全に預け、元のコピーが失われた場合にこれらのシークレットを回復できるようにするプロトコルと実装です。Anastasis AUR ({{AUR|anastasis}} および {{AUR|anastasis-gtk}}) で利用できます。詳細については、https://www.gnu.org/software/anastasis/ および https://anastasis.lu/ を参照してください。
   
 
== Troubleshooting ==
 
== Troubleshooting ==

2023年5月28日 (日) 15:56時点における版

関連記事

GNUnet は中央サーバーや信頼機関を使わないセキュアなピアツーピアネットワークを提供するフレームワークです。現在、フレームワークを使って実装されたサービスとして検閲を免れるファイル共有があります。

Wikipedia:ja:GNUnet も参照してください。

インストール

GNUnet は gnunetAUR パッケージでインストールできます。グラフィカルインターフェイスも使いたい場合は gnunet-gtkAUR をインストールしてください。

もしくは、最新の git バージョンを gnunet-gitAURgnunet-gtk-gitAUR パッケージでインストールすることもできます。

設定

gnunet サービスを起動有効化してください。

もしくは、ターミナルからピアを今すぐ起動するには:

# gnunet-arm -s

How to start and stop a GNUnet peer も参照してください。

使用方法

GNUnet ネットワークへの参入

gnunet システムサービスを 起動、場合によっては 有効化 します。一部の操作では、gnunet ユーザーサービスも開始する必要があります。

ネットワークを確認する

通常のユーザーとして gnunet-peerinfo コマンドを起動することで、ネットワークの現在の状態を確認できます。

$ gnunet-peerinfo

ピア ID の起動を確認するには:

$ gnunet-peerinfo -s

直接接続しているピア (これらを "neighbours" と呼びます) を一覧表示するには、次のコマンドを実行します。

$ gnunet-core

ファイル共有

デフォルトでは、ファイル共有サービスは ユーザーごと に実行されます。つまり、システムとユーザーの両方の gnunet サービス起動 する必要があります。このオプションを変更して マシンごと にファイル共有を実行したい場合は、それに応じて /etc/gnunet.conf を編集します。

[fs]
...
RUN_PER_USER = NO
...
UNIXPATH = $GNUNET_RUNTIME_DIR/gnunet-service-fs.sock
...

ファイルを検索する

gnunet-search を使用して、キーワード (これらは必ずしもファイル名に関連しているわけではありません) を使用してファイルを検索します。たとえば、"commons" キーワードでインデックス付けされたファイルを検索するには、次のコマンドを起動します。

$ gnunet-search --timeout='10 s' 'commons'

タイムアウトを指定しないと (上記の例では 10 秒)、gnunet-search は永久に実行され、ユーザーが CTRL-C を押すのを待ちます。

gnunet-search コマンドには、印刷出力を操作するための --printf オプションがあります。これは、find ユーティリティです。詳細については、man gnunet-search と入力してください。

検索結果を "GNUnet ディレクトリ" として保存する

gnunet-search-o オプションを使用して、検索結果を "GNUnet ディレクトリ" (.gnd ファイル) として保存します。この場合、出力は印刷されます (-s オプション)

たとえば、3 秒間検索し、"commons" キーワードによって得られた結果を three-seconds-commons.gnd という名前のファイルに保存するには、次のように起動します。

$ gnunet-search -s -t 3s -o three-seconds-commons.gnd 'commons'

後で three-seconds-commons.gnd の内容を検査したい場合は、次のコマンドを起動できます。

$ gnunet-directory three-seconds-commons.gnd

ダウンロード

gnunet-search の出力は、デフォルトでは、通常のユーザーとして直接コピーして起動できる gnunet-download コマンドのリストです。

たとえば、gnunet-search 'commons' によって生成された出力を使用すると、

$ gnunet-search 'commons'
#1:
gnunet-download -o "Liotard (2017)_ Fablab - a new space for commons based peer production.pdf" gnunet://fs/chk/C6369DRQ3S8RYK1FD5VDE666W2HVEJ5G5GJRX29BH6ZM08CBRWS7FY9326RBJ4G0N8V1RJ2N802KBYZT7RJT2EDK1J9JR2DXK5MTVM0.4SXJCK9NT5XGCZ0YAJ0ETXJJGY3P2SMNZ0Q94N775YEX9SXS2RW5FWRFK4GMBTP668Z3R8QZZ4WSHW1KG1AVQ5VFC1VF5T3WF57GT58.336423

#2:
gnunet-download -o "Rose, Carol (1986)_ The Comedy of the Commons_ Commerce, Custom, and inherently Public Property.pdf" gnunet://fs/chk/TQK3A2C279EJQ50B1TQWFNTPMGQZJJ4JXYTF2D88D03H038TB7SVVSRBT74FMYPNZ47YZSV096PVVZH0TQ3B8KBVBV2H8GN9VAASTJR.CQ7M7843MGPZCV8M26NKH6EB5MBGZAXRWCF39YS668WM6F22D214GSXNTJ4RYGE7XF68VPZM4C19XR48TT4J8WH8S2E00C96Q8K6790.1593230

#3:
gnunet-download -o "Hardin, Garett (1968)_ Tragedy of the Commons.pdf" gnunet://fs/chk/Y1FD7D123CEGWDW544YDEP15YA5E7ZD2XRSJBNP0847A5JXMMZEZ0XACGRG42BBBTGKZ0ZCBW0A9T6196Z5N26HA6SP1T8GDAT5H5SG.RN38G25DMYG3TBQJEGWDZT2B84N1JYYJZ8VRJ8HG2G1A4EFD4GH5TZXB0RXV7QEMZBSKWCCEF736FXNH6C5BYKG9DSTV99ETFGC93R0.1520328

...

起動して、

$ gnunet-download -o "Hardin, Garett (1968)_ Tragedy of the Commons.pdf" gnunet://fs/chk/Y1FD7D123CEGWDW544YDEP15YA5E7ZD2XRSJBNP0847A5JXMMZEZ0XACGRG42BBBTGKZ0ZCBW0A9T6196Z5N26HA6SP1T8GDAT5H5SG.RN38G25DMYG3TBQJEGWDZT2B84N1JYYJZ8VRJ8HG2G1A4EFD4GH5TZXB0RXV7QEMZBSKWCCEF736FXNH6C5BYKG9DSTV99ETFGC93R0.1520328

これにより、現在のディレクトリに Hardin, Garett (1968)_ Tragedy of the Commons.pdf がダウンロードされます。

リモート GNUnet ディレクトリをダウンロードせずにマウントする

gnunet-fuseAUR という名前のモジュールは、GNUnet ネットワークからリモート ディレクトリをマウントするために開発されました。gnunet-fuse を使用すると、GNUnet ネットワーク上に公開されたディレクトリを読み取り専用ファイルシステムとしてマウントし、通常のファイル操作を使用してアクセスできます。gnunet-download を介してディレクトリを再帰的にダウンロードするのとは対照的に、これにはファイルがオンデマンドでダウンロードされるという利点があります。アクセスしたファイル (またはディレクトリ) のみがダウンロードされます。詳細については、モジュールをインストールし、"man gnunet-fuse" と入力してください。

アップロード

GNUnet ファイル共有ネットワーク上でファイルを公開するには、後で他の人がファイルを検索するために使用できるキーワードを選択する必要があります。

キーワードは厳密には必須ではありませんが、推奨されます。これは、GNUnet ではファイル名ではなくキーワードによる検索が許可されているためです。GNUnet の依存関係である libextractor ライブラリは、ファイルからキーワードを自動的に抽出できますが、独自のキーワードを入力することもできます。

次の例では、キーワード "commons" と "state" を使用して、ostrom.pdf という名前のファイルを公開します。

$ gnunet-publish -k 'commons' -k 'state' ostrom.pdf
Publishing `/srv/filesharing/gnunet/ostrom.pdf' done.
URI is `gnunet://fs/chk/M57S...

GNUnet ユーザーは、gnunet-search コマンドを使用してファイルを検索できるようになりました。

$ gnunet-search 'commons'
#1:
gnunet-download -o "ostrom.pdf" gnunet://fs/chk/M57S...

現在公開されているすべてのファイルをリストするには、gnunet-fs -i を起動します。後でファイルの共有を停止したい場合は、gnunet-unindex filename を使用できます (この例では、gnunet-unindex 'ostrom.pdf')

ファイルが公開されると、ファイルのインデックスに使用されたキーワードを取得することはできません (つまり、逆検索) ただし、さらにキーワードを追加することはいつでも可能です。

新しくアップロードされたファイルがピアに表示されるまでには、しばらく時間がかかる (最大で数時間) 場合があることに注意してください。

警告: ファイルを非公開にしても、現在のマシンによるファイルの共有が停止されるだけで、GNUnet ネットワークからファイルが消去されることはありません。これは設計上不可能です。他の人がファイルをダウンロードして自分で共有している可能性があるためです。必ず、gnunet-publish取り消しできないアクション であると考えてください。

gnunet-publish コマンドには、インデックスを付けずにファイルを公開するためのオプション -n または同等の --noindex が用意されています。使用すると、GNUnet は完全な挿入を実行し、ファイル全体を暗号化された形式で GNUnet データベースに保存します。

このオプションは、検閲が厳しい国で検閲されたファイルの場合に、GNUnet を実行しているコンピュータに物理的にアクセスした人が現在公開されているファイルを知ることを回避する目的で作成されました。--noindex オプションを使用して公開されたファイルは、ネットワークからダウンロードされたチャンクとして表示されるため、非公開またはインデックス付けを解除することはできません (そもそもインデックス付けされていません)。ただし、公開中にコンテンツの優先順位を低く指定し (--prio)、データベースがいっぱいになったときに公開されるコンテンツが簡単に失われてもよいことを GNUnet に伝えることは常に可能です。

詳細については、the chapter on file-sharing in the handbook を参照してください。https://gnunet.org/en/use.html#filesharing も参照してください。

インデックス付きファイルの変更と削除
  • ファイルを変更すると、ファイルのURIが変わります。したがって、GNUnet はこれをまったく別のファイルと見なし、インデックス付きファイルは見つからないとみなします。したがって、最初に元のファイルのインデックスが解除されていることを確認し (gnunet-unindex コマンドを使用)、ファイルを変更してから、新しいファイルにインデックスを付けて、ネットワーク経由でアクセスできるようにします。
  • ファイルシステムからファイルを削除する場合は、まずそのファイルのインデックスを解除する必要があります。
  • 公開されたファイルを多かれ少なかれ頻繁に更新する必要があることが事前にわかっている場合は、GNUnet#更新可能なファイルの公開 を参照してください。

ダウンロード + 共有

GNUnet ファイル共有ネットワークは DHT です (Wikipedia:ja:分散ハッシュテーブル を参照) DHT のピアとして、ユーザーはさまざまなファイルのチャンクをディスク上に保存します。これは、ダウンロードしていないファイルやダウンロードしたファイルであっても です。どのファイルが保存されるかは、DHT 距離メトリック/アルゴリズムによって異なります。

技術的には、ファイルが完全にダウンロードされていない限り、ファイルの一部のみが保存されます。これらはキャッシュ (通常は /var/lib/gnunet/.local/share/gnunet の下) に保存されます。DHT クエリがキャッシュされた部分の 1 つについてピアに到達すると、ピアはそれを提供します。ファイル共有ブロックの保存に使用されるデータベースは有限 (構成可能なクォータ以下) に保たれ、すべてのキャッシュされた部分は期限切れになり、新しいファイル用のスペースを確保できます。

誰かが GNUnet ネットワークでファイルを共有すると、そのファイルの分散チャンクはネットワークのキャッシュにしばらく残り、ファイルを共有した人がオフラインになってもファイルは利用可能なままになります。しかし、元の発行者が行方不明になり、他の誰もファイルを 明示的に (gnunet-publish を使用して) 共有しなかった場合、ピアのキャッシュが期限切れになるか、ピアがオフラインになると、そのファイルは最終的に利用できなくなります。

ファイルが GNUnet ネットワークに確実に残るようにする唯一の方法は、ファイルをダウンロードした後に (gnunet-publish を使用して) 明示的に再公開し、ファイルを公開するマシンが定期的にネットワークにアクセスできるようにすることです。

ダウンロード後にファイルを公開すると、再公開用に選択されたキーワードに関係なく、ファイルがダウンロードされたときと同じ URI (以下の例では gnunet://fs/chk/Y1FD...) が常に生成されます。

$ gnunet-download -o 'Hardin, Garett (1968)_ Tragedy of the Commons.pdf' gnunet://fs/chk/Y1FD...
100% [============================================================]
Downloading `Hardin, Garett (1968)_ Tragedy of the Commons.pdf' done (160 b/s).
$ gnunet-publish -k 'tragedy' 'Hardin, Garett (1968)_ Tragedy of the Commons.pdf'
Publishing `/srv/filesharing/gnunet/Hardin, Garett (1968)_ Tragedy of the Commons.pdf' done.
URI is `gnunet://fs/chk/Y1FD...

VPN

GNUnet は VPN を提供しており、これを使用してインターネット接続を共有したり (これは Tor 出口ノードを実行するのと同じように危険な可能性があります)、ホスト上のサービスへのアクセスを提供したりできます (これらのサービスは安全です)

GNUnet で VPN をセットアップする方法については、https://gnunet.org/en/use.html#vpn を参照してください。

GNU ネームサービス (GNS)

GNU ネーム サービス (GNS) は、ドメイン名前解決 (DNS) に代わる完全に分散化された代替手段であり、後者と同じ重大なセキュリティ上の欠陥に悩まされることはありません (セキュリティの問題 を参照)

GNS の使用方法については、https://gnunet.org/en/use.html#gns_cli および https://gnunet.org/en/use.html#gns_browser を参照してください。

他の GNUnet ユーザーとチャットする

GNUnet ユーザーとチャットするには、gnunet-messenger ユーティリティを使用できます。"これには、gnunet.service ユーザーユニット起動 する必要があります" (おそらく、gnunet.service システムユニットと一緒に – マルチユーザー設定で現在のユーザーとしてデーモンを起動する を参照してください) たとえば、"アリス" というニックネームを使用して "miscellanea" ルームに入るには、

$ gnunet-messenger -e alice -r miscellanea
* Welcome to the messenger, 'alice'!
* You try to open a room...
* You joined the room.
[EHDA8T] * 'anonymous' opened the room on: 2ABN944E16FTWFMOKTMQ5JMPQ233YSPBKC47XR2DHSPQCQ8GYK80
[EHDA8T] * 'anonymous' gets renamed to 'alice'
█

アプリのエコシステム

GNUnet GTK

GNUnet GTK は、GNUnet フレームワーク用のグラフィカルインターフェイスのコレクションです。以下の GTK アプリケーションが同梱されています。

  • gnunet-conversation-gtk
  • gnunet-fs-gtk
  • gnunet-namestore-gtk
  • gnunet-peerinfo-gtk
  • gnunet-setup
  • gnunet-statistics-gtk

GNUnet GTK をインストールするには、gnunet-gtkAUR パッケージをダウンロードします。

GTK メッセンジャー

現在、GNUnet ネットワーク上でチャットするためのいくつかのグラフィカルユーザーインターフェイスが開発されています。そのうちの 1 つは、モバイル対応の GTK である Messenger GTK (messenger-gtkAUR、または開発バージョンの場合は messenger-gtk-gitAUR) です。コマンドラインを介したチャットについては、Messenger CLI (開発バージョンの場合は messenger-cliAUR または messenger-cli-gitAUR) を参照してください。

Web ユーザーインターフェース

GNUnet の Web インターフェースが存在し、gnunet-webui-gitAUR として入手できます。

re:claimID

re:claimID は、GNU ネーム システム上に構築された分散型アイデンティティプロバイダー (IdP) サービスです。これにより、ユーザーは標準化されたプロトコル (OpenID Connect) を使用して Web サイトと個人情報を安全に共有できます。

ユーザー向けに re:claimIDFirefox の拡張機能拡張機能 を提供します。 Chromium の拡張機能] Web ブラウザで re:claimID ID を管理するための拡張機能 (gnunetAUR パッケージをインストールする必要があります)

拡張機能をインストールした後、https://ui.reclaim/ にアクセスして、ローカルの re:claimID インスタンスに新しい ID を追加し、それにいくつかの属性を追加できるようになります (拡張機能がないとリンクは機能しません) インストールされています。

詳細については、マニュアル を参照してください。

GNU Taler

GNU Taler は、GNUnet 上に構築されたマイクロトランザクションおよび電子決済システムです。他の分散型決済システムとは異なり、Taler はブロックチェーンに基づいておらず、代わりにブラインド署名に基づいています。

詳細については、公式ドキュメント を参照してください。パッケージ syncAURtaler-exchangeAURtaler-mdbAURtaler-merchantAUR、および taler-twisterAUR も参照してください。

GNU Anastasis

Anastasis は、ユーザーがオープンセットのエスクロープロバイダーにコア シークレットを安全に預け、元のコピーが失われた場合にこれらのシークレットを回復できるようにするプロトコルと実装です。Anastasis は AUR (anastasisAUR および anastasis-gtkAUR) で利用できます。詳細については、https://www.gnu.org/software/anastasis/ および https://anastasis.lu/ を参照してください。

Troubleshooting

GNUnet fails to publish files

A common mistake for who does not understand how the GNUnet services work is that of trying to publish files located in the home directory (or in its subdirectories) when the file sharing service is not running for the current user. The problem is that the gnunet system user (which runs the GNUnet system service) has normally no access to the home directories of other users.

An easy solution is to create a shared directory, where only users that belong to the gnunet group have write permissions, and use it to place the files that will be published. For instance, /srv/filesharing/gnunet could be a good choice:

# install -dm775 -g gnunet -o gnunet /srv/filesharing/gnunet

Each user belonging to the gnunet group can then create a link to it in their home directory,

$ ln -s /srv/filesharing/gnunet ~/Publishing

which can be dereferenced by gnunet-publish:

$ (cd ~/Publishing && gnunet-publish -k commons ostrom.pdf) && gnunet-fs -i
/srv/filesharing/gnunet/ostrom.pdf

If you prefer to run the file sharing service as current user, edit /etc/gnunet.conf accordingly:

[fs]
...
RUN_PER_USER = YES
...
UNIXPATH = $GNUNET_USER_RUNTIME_DIR/gnunet-service-fs.sock
...

Low bandwidth

It is recommended for file-sharing that you increase GNUnet's bandwidth restrictions from the actually pretty low defaults. The example below sets the WAN and LAN limits to unlimited.

$ gnunet-config -s ats -o WAN_QUOTA_IN -V unlimited
$ gnunet-config -s ats -o WAN_QUOTA_OUT -V unlimited
$ gnunet-config -s ats -o LAN_QUOTA_IN -V unlimited
$ gnunet-config -s ats -o LAN_QUOTA_OUT -V unlimited

/var/lib/gnunet/ grows too big

GNUnet's cache is kept finite and cannot grow forever. However the quota reserved for it by default is not small (currently 5 GB). To reduce this number, you must assign your preferred value to the QUOTA key in the datastore section of /etc/gnunet.conf.

/etc/gnunet.conf
...

[datastore]
...
QUOTA = 2 GB
...

/var/lib/gnunet/ is left after uninstall

The /var/lib/gnunet/ directory is the home directory of the gnunet system user, which is left after uninstalling GNUnet. If you are sure that you are never going to use GNUnet ever again, launch:

# userdel -r gnunet
# groupdel gnunetdns
警告: The identity and all the information about the network cumulatively stored by the current peer will be destroyed – this will not affect files explicitly downloaded in other paths.

The network is too static

By default GNUnet bootstraps itself using a hostlist file downloaded from internet (plain https) every time it connects to the network. If you want to instruct it to learn and memorize host lists provided by other peers you need to add the -e option to the OPTIONS key under hostlist in /etc/gnunet.conf. Further options are also available.

/etc/gnunet.conf
...

[hostlist]
...
# Options:
# -p : provide a hostlist as a hostlist servers
# -b : bootstrap using configured hostlist servers
# -e : enable learning advertised hostlists
# -a : advertise hostlist to other servers
OPTIONS = -b -e -a -p
...

Tips and tricks

Launching the daemon as current user in a multi-user setup

After a fresh install the user configuration file is missing. In a multi-user setup this is almost only used (if needed) to start and stop the gnunet.service user unit while the system daemon is running, hence it is generally enough to create a minimal configuration file containing only:

~/.config/gnunet.conf
[arm]
START_SYSTEM_SERVICES = NO
START_USER_SERVICES = YES

Without setting START_SYSTEM_SERVICES to NO, launching the daemon as current user while the system daemon is running will result in duplicate processes.

See The Multi-User Setup, in the manual for further insight.

A button for switching GNUnet on and off

If you use GNOME you might want to install the Systemd Manager shell extension (gnome-shell-extension-systemd-managerAUR) and add GNUnet to it:

$ dconf write /org/gnome/shell/extensions/systemd-manager/systemd \
	'['\''{"name":"GNUnet system service","service":"gnunet.service","type":"system"}'\'', '\''{"name":"GNUnet user service","service":"gnunet.service","type":"user"}'\'']'

(After installing the extension you might need to restart the session.)

Single-user setup

The GNUnet peer can be started also from the current user without running the gnunet system service. For a single-user setup make sure that START_SYSTEM_SERVICES and START_USER_SERVICES are set to YES in ~/.config/gnunet.conf:

~/.config/gnunet.conf
[arm]
START_SYSTEM_SERVICES = YES
START_USER_SERVICES = YES

To start the peer as current user, start the gnunet.service user unit. To stop a peer which is running as current user, stop the gnunet.service user unit.

For further information, please refer to the chapter on the single-user setup in the handbook.

Publishing updatable files

It is possible to publish "updatable" files (i.e., files for which you might want to release a different version in the future, advertising that it is the same file – just updated – and not a different one). To release an updatable file you need to create an ego and use it to sign the file. This is the only way to assure that a malicious party cannot supply counterfeited updates.

To create an ego the gnunet-identity utility is available, for which the gnunet.service user unit needs to be started (possibly along with the gnunet.service system unit – see #Launching the daemon as current user in a multi-user setup). For instance, to create an ego named "caroline", start the gnunet user unit and launch:

$ gnunet-identity -C caroline
ノート: If later you decide to erase this ego you can launch gnunet-identity -D caroline.

Now that you have created an ego, you need to specify a string that identifies the current release of the file (the -t option), and already now the string that will identify your planned next version (the -N option) – you will have to remember the latter. Any content is possible for both strings.

$ gnunet-publish -P caroline -t 'diary version 1' -N 'diary version 2' -k 'diary' until-2020/my_diary.md
Publishing `/srv/filesharing/gnunet/until-2020/my_diary.md' done.
URI is `gnunet://fs/chk/AF26...'.

Namespace URI is `gnunet://fs/sks/V3TK.../diary version 1'.

When an update will be ready, you will have to use the same string that you had previously chosen for it ("diary version 2" in our example), possibly accompanying it with another name for a further update (if applicable):

$ gnunet-publish -P caroline -t 'diary version 2' -N 'diary version 3' -k 'diary' until-2021/my_diary.md
Publishing `/srv/filesharing/gnunet/until-2021/my_diary.md' done.
URI is `gnunet://fs/chk/5Y7V...'.

Namespace URI is `gnunet://fs/sks/V3TK.../diary version 2'.

If you decide that an update will be the last one, omit the -N option (will not allow any future updates).

Note that an update with GNUnet will not make the old content unavailable, GNUnet merely allows the publisher to point users to more recent versions.

systemd を使用しない GNUnet の起動と停止

GNUnet には、独自のデーモン管理システムである 自動再起動マネージャー (GNUnet サービスに限定) が付属しています。

systemd を使用せずにシステム サービスを手動で開始するには、gnunet-arm ユーティリティを「gnunet ユーザー として起動します。

$ sudo -u gnunet gnunet-arm -c /etc/gnunet.conf -s

systemd を使用せずにシステム サービスを手動で終了するには、次のコマンドを起動します。

$ sudo -u gnunet gnunet-arm -c /etc/gnunet.conf -e

systemd を使用せずにユーザー サービスを手動で開始するには、gnunet-arm ユーティリティを 現在のユーザーとして 起動します。

$ gnunet-arm -c ~/.config/gnunet.conf -s

systemd を使用せずにユーザーサービスを手動で終了するには、次のコマンドを起動します。

$ gnunet-arm -c ~/.config/gnunet.conf -e