10 o test suite dependencies
11 o optional dependencies
14 * Scope of Operating System support
17 o Building GNUnet from source
18 o Notes on compiling from Git
22 * Running HTTP on port 80 and HTTPS on port 443
29 GNUnet is peer-to-peer framework providing a network abstractions and
30 applications focusing on security and privacy. So far, we have
31 created applications for anonymous file-sharing, decentralized naming
32 and identity management, decentralized and confidential telephony and
33 tunneling IP traffic over GNUnet. GNUnet is currently developed by a
34 worldwide group of independent free software developers. GNUnet is a
35 GNU package (http://www.gnu.org/).
37 This is an ALPHA release. There are known and significant bugs as
38 well as many missing features in this release.
40 GNUnet is free software released under the GNU Affero General Public
41 License (v3 or later). For details see the COPYING file in this
42 directory. If you fork this software, you MUST adjust GNUNET_AGPL_URL
43 in src/include/gnunet_util_lib.h to point to the source code of your
46 Additional documentation about GNUnet can be found at
47 https://gnunet.org/ and in the 'doc/' folder.
48 Online documentation is provided at
49 'https://docs.gnunet.org' and 'https://tutorial.gnunet.org'.
55 The dependencies for building GNUnet will require around 0.74 GiB
56 diskspace. GNUnet itself will require 8 - 9.2 MiB depending on
59 These are the direct dependencies for running GNUnet:
60 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
62 - Bash (for some scripts)
64 - gnutls >= 3.2.12 (highly recommended a gnutls
65 linked against libunbound)
66 - A curl build against gnutls, or gnurl:
67 * libgnurl >= 7.35.0 (recommended, available from
68 https://gnunet.org/en/gnurl.html)
70 * libcurl >= 7.35.0 (alternative to libgnurl)
72 - libunistring >= 0.9.2
77 - libmicrohttpd >= 0.9.63 (strongly recommended for
78 a wide range of features)
81 - nss (certutil binary, for
82 gnunet-gns-proxy-setup-ca)
83 - openssl >= 1.0 (binary, used to generate
85 for gnunet-gns-proxy-setup-ca)
86 - pkgconf or pkg-config
87 - A Posix shell (for some scripts)
89 - libltdl >= 2.2 (part of GNU libtool)
90 - 1 or more databases:
91 * sqlite >= 3.8 (default database, required)
93 * mysql >= 5.1 (alternative to sqlite)
95 * postgres >= 9.5 (alternative to sqlite)
96 - which (contrib/apparmor(?), gnunet-bugreport,
99 - argon2 >= 20190702 (for proof-of-work calculations in
101 - libsodium >= 1.0.11 (for elliptic curve cryptography)
103 These are the dependencies for GNUnet's testsuite:
104 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
106 - Bash (for some tests[*4])
107 - A Posix Shell (for some tests)
108 - python >= 3.4 (3.4 and higher technically supported,
109 at least python 3.7 tested to work)
119 These are the optional dependencies:
120 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
122 - awk (for linting tests)
123 - Bash (for Docker and Vagrant)
124 - bluez (for bluetooth support)
125 - grof (for linting of man pages)
126 - libextractor >= 0.6.1 (highly recommended[*5])
128 - libopus >= 1.0.1 (for conversation tool)
129 - libpulse >= 2.0 (for conversation tool)
130 - libogg >= 1.3.0 (for conversation tool)
131 - libnss (certtool binary (for convenient
132 installation of GNS proxy))
133 - libzbar >= 0.10 (for gnunet-qr)
134 - libpbc >= 0.5.14 (for Attribute-Based Encryption and
135 Identity Provider functionality)
136 - libgabe (for Attribute-Based Encryption and
137 Identity Provider functionality, from
138 https://github.com/schanzen/libgabe)
139 - mandoc (for linting of man pages, generation of
140 html output of man pages (not part of
143 - perl5 (for some utilities)
144 - TeX Live >= 2012 (for gnunet-bcd[*])
145 - texi2mdoc (for automatic mdoc generation [*2], not
146 the texi2mdoc script distributed with
147 autogen but the texi2mdoc C application)
149 Recommended autotools for compiling the Git version are:
150 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
157 [*] Mandatory for compiling the info output of the documentation,
158 a limited subset ('texlive-tiny' in Guix) is enough.
160 [*1] The default configuration is to build the info output of the
161 documentation, and therefore require texinfo. You can pass
162 '--disable-documentation' to the configure script to change this.
164 [*2] If you still prefer to have documentation, you can pass
165 '--enable-texi2mdoc-generation' to build the mdocml ("mandoc")
166 documentation (experimental stages in gnunet).
167 If this proves to be reliable, we will
168 include the mdocml output in the release tarballs.
169 Contrary to the name, texi2mdoc does not require Texinfo,
170 It is a standalone ISO C utility.
172 [*3] GNU make introduced the != operator in version 4.0.
173 GNU make was released in october 2013, reasonable to
174 be widespread by now. If this is not working out for
175 you, open a bug so that we can get a more portable
178 [*4] We are commited to portable tools and solutions
179 where possible. New scripts should be Posix sh
180 compatible, current and older scripts are
181 in the process of being rewritten to comply
182 with this requirement.
184 [*5] While libextractor ("LE") is optional, it is recommended to
185 build gnunet against it. If you install it later,
186 you won't benefit from libextractor.
187 If you are a distributor, we recommend to split
188 LE into basis + plugins rather than making LE
189 an option as an afterthought by the user.
190 LE itself is very small, but its dependency chain
191 on first, second, third etc level can be big.
192 There is a small effect on privacy if your LE build
193 differs from one which includes all
194 plugins (plugins are build as shared objects):
195 if users publish a directory with a mixture of file
196 types (for example mpeg, jpeg, png, gif) the
197 configuration of LE could leak which plugins are
198 installed for which filetypes are not providing
200 However, this leak is just a minor concern.
205 For a correct functionality depending on the host OS, you need
206 to run the equivalent of these steps after installation.
207 Replace $(DESTDIR)$(libexecdir) with the appropriate paths,
208 for example /usr/local/lib/gnunet/libexec/. Note that this
209 obviously must be run as priviledged user.
211 chown root:root $(DESTDIR)$(libexecdir)/gnunet-helper-vpn
212 chmod u+s $(DESTDIR)$(libexecdir)/gnunet-helper-vpn
213 chown root:root $(DESTDIR)$(libexecdir)/gnunet-helper-transport-wlan
214 chmod u+s $(DESTDIR)$(libexecdir)/gnunet-helper-transport-wlan
215 chown root:root $(DESTDIR)$(libexecdir)/gnunet-helper-transport-bluetooth
216 chmod u+s $(DESTDIR)$(libexecdir)/gnunet-helper-transport-bluetooth
217 chown root $(DESTDIR)$(libexecdir)/gnunet-helper-dns
218 chgrp $(GNUNETDNS_GROUP) $(DESTDIR)$(libexecdir)/gnunet-helper-dns
219 chmod 4750 $(DESTDIR)$(libexecdir)/gnunet-helper-dns
220 chgrp $(GNUNETDNS_GROUP) $(DESTDIR)$(libexecdir)/gnunet-helper-dns
221 chown gnunet:$(GNUNETDNS_GROUP) $(DESTDIR)$(libexecdir)/gnunet-helper-dns
222 chmod 2750 $(DESTDIR)$(libexecdir)/gnunet-helper-dns
223 chown root:root $(DESTDIR)$(libexecdir)/gnunet-helper-exit
224 chmod u+s $(DESTDIR)$(libexecdir)/gnunet-helper-exit
225 chown root:root $(DESTDIR)$(libexecdir)/gnunet-helper-nat-server
226 chown root:root $(DESTDIR)$(libexecdir)/gnunet-helper-nat-client
227 chmod u+s $(DESTDIR)$(libexecdir)/gnunet-helper-nat-server
228 chmod u+s $(DESTDIR)$(libexecdir)/gnunet-helper-nat-client
231 Scope of Operating System support
232 =================================
234 We actively support GNUnet on a broad range of Free Software Operating
237 For proprietary Operating Systems, like for example Microsoft Windows
238 or Apple OS X, we accept patches if they don't break anything for
239 other Operating Systems.
240 If you are implementing support for a proprietary Operating System,
241 you should be aware that progress in our codebase could break
242 functionality on your OS and cause unpredicted behavior we can
243 not test. However, we do not break support on Operating Systems
244 with malicious intent.
245 Regressions which do occur on these Operating Systems are 3rd
246 class issues and we expect users and developers of these
247 Operating Systems to send proposed patches to fix regressions.
249 For more information about our stand on some of the motivating
250 points here, read the 'Philosophy' Chapter of our handbook.
259 We recommend to use binary packages provided by the package manager integrated
260 within your Operating System. GNUnet is reportedly available for at least:
262 ALT Linux, Archlinux, Debian, Deepin, Devuan, GNU Guix, Hyperbola,
263 Kali Linux, LEDE/OpenWRT, Manjaro, Nix, Parabola, Pardus, Parrot,
264 PureOS, Raspbian, Rosa, Trisquel, and Ubuntu.
266 If GNUnet is available for your Operating System and it is missing,
267 send us feedback so that we can add it to this list. Furthermore, if
268 you are interested in packaging GNUnet for your Operating System,
269 get in touch with us at gnunet-developers@gnu.org if you require
272 If you were using an Operating System with the apt package manager,
273 GNUnet could be installed as simple as:
275 $ apt-get install gnunet
277 Generic installation instructions are in the INSTALL file in this
280 Building GNUnet from source
281 ~~~~~~~~~~~~~~~~~~~~~~~~~~~
283 IMPORTANT: You can read further notes about compilation from source in
284 the handbook under doc/handbook/, which includes notes about specific
285 requirements for operating systems aswell. If you are a package
286 mantainer for an Operating System we invite you to add your notes if
287 you feel it is necessary and can not be covered in your Operating
288 System's documentation.
290 Two prominent examples which currently lack cross-compilation
291 support in GNUnet (and native binaries) are MS Windows and Apple macOS.
292 For macOS we recommend you to do the build process via Homebrew and a
293 recent XCode installation. We don't recommend using GNUnet with any
294 recent MS Windows system as it officially spies on its users (according
295 to its T&C), defying some of the purposes of GNUnet.
297 Note that some functions of GNUnet require "root" access. GNUnet will
298 install (tiny) SUID binaries for those functions is you run "make
299 install" as root. If you do not, GNUnet will still work, but some
300 functionality will not be available (including certain forms of NAT
303 GNUnet requires the GNU MP library (https://www.gnu.org/software/gmp/)
304 and libgcrypt (https://www.gnupg.org/). You can specify the path to
305 libgcrypt by passing "--with-gcrypt=PATH" to configure. You will also
306 need either sqlite (http://www.sqlite.org/), MySQL
307 (http://www.mysql.org/) or PostGres (http://www.postgres.org/).
309 If you install from source, you need to install GNU libextractor first
310 (download from https://www.gnu.org/software/libextractor/). We also
311 recommend installing GNU libmicrohttpd (download from
312 https://www.gnu.org/software/libmicrohttpd/). Furthermore we recommend
313 libgnurl (from https://gnunet.org/en/gnurl.html).
314 Then you can start the actual GNUnet compilation process with:
317 $ export GNUNET_PREFIX=/usr/local/lib # or other directory of your choice
319 # adduser --system --home "/var/lib/gnunet" --group gnunet --shell /bin/sh
320 # ./configure --prefix=$GNUNET_PREFIX/.. --with-extractor=$LE_PREFIX
323 And finally install GNUnet with:
327 Complete the process by either adjusting one of our example service files
328 in 'contrib/services' or by running:
330 # sudo -u gnunet gnunet-arm -s
333 Note that you must read paragraph "Notes on setuid", which documents steps you
334 have to follow after the installation, as a priviledged user. We require some
335 binaries to be setuid. The most portable approach across all supported
336 platforms and targets is to let this be handled manually.
337 The installation will work if you do not run these steps as root, but some
338 components may not be installed in the perfect place or with the right
339 permissions and thus won't work.
341 This will create the users and groups needed for running GNUnet
342 securely and then compile and install GNUnet to $GNUNET_PREFIX/../bin/,
343 $GNUNET_PREFIX/ and $GNUNET_PREFIX/../share/ and start the system
344 with the default configuration. It is strongly recommended that you
345 add a user "gnunet" to run "gnunet-arm". You can then still run the
346 end-user applications as another user.
348 If you create a system user "gnunet", it is recommended that you edit
349 the configuration file slightly so that data can be stored in the
350 system user home directory at "/var/lib/gnunet". Depending on what
351 the $HOME-directory of your "gnunet" user is, you might need to set
352 the SERVICEHOME option in section "[PATHS]" to "/var/lib/gnunet" to
353 do this. Depending on your personal preferences, you may also want to
354 use "/etc/gnunet.conf" for the location of the configuration file in
355 this case (instead of ~gnunet/.config/gnunet.conf"). In this case,
356 you need to start GNUnet using "gnunet-arm -s -c /etc/gnunet.conf" or
357 set "XDG_CONFIG_HOME=/etc/".
359 You can avoid running 'make install' as root if you have extensive sudo rights
360 (can run "chmod +s" and "chown" via 'sudo'). If you run 'make install' as a
361 normal user without sudo rights (or the configure option), certain binaries
362 that require additional privileges will not be installed properly (and
363 autonomous NAT traversal, WLAN, DNS/GNS and the VPN will then not work).
365 If you run 'configure' and 'make install' as root, GNUnet's build system will
366 install "libnss_gns*" libraries to "/lib/" regardless (!) of the
367 $GNUNET_PREFIX you might have specified, as those libraries must be in
368 "/lib/". If you are packaging GNUnet for binary distribution, this may cause
369 your packaging script to miss those plugins, so you might need to do some
370 additional manual work to include those libraries in your binary package(s).
371 Similarly, if you want to use the GNUnet Name System and did NOT run
372 GNUnet's 'make install' process with priviledged rights, the libraries will be
373 installed to "$GNUNET_PREFIX" and you will have to move them to "/lib/"
376 Notes on compiling from Git
377 ~~~~~~~~~~~~~~~~~~~~~~~~~~~
379 Finally, if you are compiling the code from git, you have to
380 run "sh ./bootstrap" before running "./configure". If you receive an error during
381 the running of "sh ./bootstrap" that looks like "macro `AM_PATH_GTK'
382 not found in library", you may need to run aclocal by hand with the -I
383 option, pointing to your aclocal m4 macros, i.e.
385 $ aclocal -I /usr/local/share/aclocal
391 Note that additional, per-user configuration files can be created by
392 each user. However, this is usually not necessary as there are few
393 per-user options that normal users would want to modify. The defaults
394 that are shipped with the installation are usually just fine.
396 The gnunet-setup tool is particularly useful to generate the master
397 configuration for the peer. gnunet-setup can be used to configure and
398 test (!) the network settings, choose which applications should be run
399 and configure databases. Other options you might want to control
400 include system limitations (such as disk space consumption, bandwidth,
401 etc). The resulting configuration files are human-readable and can
402 theoretically be created or edited by hand.
404 gnunet-setup is a separate download and requires somewhat recent
405 versions of GTK+ and Glade. You can also create the configuration file
406 by hand, but this is not recommended. For more general information
407 about the GNU build process read the INSTALL file.
409 GNUnet uses two types of configuration files, one that specifies the
410 system-wide defaults (typically located in
411 $GNUNET_PREFIX/../share/gnunet/config.d/) and a second one that overrides
412 default values with user-specific preferences. The user-specific
413 configuration file should be located in "~/.config/gnunet.conf" or its
414 location can be specified by giving the "-c" option to the respective
417 For more information about the configuration (as well as usage) refer
418 to the 'GNUnet User Handbook' chapter of the documentation, included
419 in this software distribution.
425 For detailed usage notes, instructions and examples, refer to the
426 included 'GNUnet Handbook'.
428 First, you must obtain an initial list of GNUnet hosts. Knowing a
429 single peer is sufficient since after that GNUnet propagates
430 information about other peers. Note that the default configuration
431 contains URLs from where GNUnet downloads an initial hostlist
432 whenever it is started. If you want to create an alternative URL for
433 others to use, the file can be generated on any machine running
434 GNUnet by periodically executing
436 $ cat $SERVICEHOME/data/hosts/* > the_file
438 and offering 'the_file' via your web server. Alternatively, you can
439 run the build-in web server by adding '-p' to the OPTIONS value
440 in the "hostlist" section of gnunet.conf and opening the respective
441 HTTPPORT to the public.
443 If the solution with the hostlist URL is not feasible for your
444 situation, you can also add hosts manually. Simply copy the hostkeys
445 to "$SERVICEHOME/data/hosts/" (where $SERVICEHOME is the directory
446 specified in the gnunet.conf configuration file). You can also use
447 "gnunet-peerinfo -g" to GET a URI for a peer and "gnunet-peerinfo -p
448 URI" to add a URI from another peer. Finally, GNUnet peers that use
449 UDP or WLAN will discover each other automatically (if they are in the
450 vicinity of each other) using broadcasts (IPv4/WLAN) or multicasts
453 The local node is started using "gnunet-arm -s". We recommend to run
454 GNUnet 24/7 if you want to maximize your anonymity, as this makes
455 partitioning attacks harder.
457 Once your peer is running, you should then be able to access GNUnet
460 $ gnunet-search KEYWORD
462 This will display a list of results to the console. You can abort
463 the command using "CTRL-C". Then use
465 $ gnunet-download -o FILENAME GNUNET_URI
467 to retrieve a file. The GNUNET_URI is printed by gnunet-search
468 together with a description. To publish files on GNUnet, use the
469 "gnunet-publish" command.
472 The GTK user interface is shipped separately.
473 After installing gnunet-gtk, you can invoke the setup tool and
474 the file-sharing GUI with:
479 For further documentation, see our webpage or the 'GNUnet User Handbook',
480 included in this software distribution.
486 Contributions are welcome. Please submit bugs you find to
487 https://bugs.gnunet.org/ or our bugs mailinglist.
488 Please make sure to run the script "contrib/scripts/gnunet-bugreport"
489 and include the output with your bug reports. More about how to
490 report bugs can be found in the GNUnet FAQ on the webpage. Submit
491 patches via E-Mail to gnunet-developers@gnu.org, formated with
494 In order to run the unit tests by hand (instead of using "make check"),
495 you need to set the environment variable "GNUNET_PREFIX" to the
496 directory where GNUnet's libraries are installed.
497 Before running any testcases, you must complete the installation.
501 $ ./configure --prefix=$SOMEWHERE
504 $ export $GNUNET_PREFIX=$SOMEWHERE
507 Some of the testcases require python >= 3.4, and the python module
508 "pexpect" to be installed.
509 If any testcases fail to pass on your system, run
510 "contrib/scripts/gnunet-bugreport" (in the repository) or "gnunet-bugreport"
511 when you already have GNUnet installed and report its output together with
512 information about the failing testcase(s) to the Mantis bugtracking
513 system at https://bugs.gnunet.org/.
516 Running HTTP on port 80 and HTTPS on port 443
517 =============================================
519 In order to hide GNUnet's HTTP/HTTPS traffic perfectly, you might
520 consider running GNUnet's HTTP/HTTPS transport on port 80/443.
521 However, we do not recommend running GNUnet as root. Instead, forward
522 port 80 to say 1080 with this command (as root, in your startup
525 # iptables -t nat -A PREROUTING -p tcp -m tcp --dport 80 -j REDIRECT --to-ports 1080
529 # iptables -t nat -A PREROUTING -p tcp -m tcp --dport 443 -j REDIRECT --to-ports 4433
531 Then set in the HTTP section of gnunet.conf the "ADVERTISED_PORT" to
532 "80" and "PORT" to 1080 and similarly in the HTTPS section the
533 "ADVERTISED_PORT" to "443" and "PORT" to 4433.
535 You can do the same trick for the TCP and UDP transports if you want
536 to map them to a priviledged port (from the point of view of the
537 network). However, we are not aware of this providing any advantages
540 If you are already running an HTTP or HTTPS server on port 80 (or 443),
541 you may be able to configure it as a "ReverseProxy". Here, you tell
542 GNUnet that the externally visible URI is some sub-page on your website,
543 and GNUnet can then tunnel its traffic via your existing HTTP server.
544 This is particularly powerful if your existing server uses HTTPS, as
545 it makes it harder for an adversary to distinguish normal traffic to
546 your server from GNUnet traffic. Finally, even if you just use HTTP,
547 you might benefit (!) from ISP's traffic shaping as opposed to being
548 throttled by ISPs that dislike P2P. Details for configuring the
549 reverse proxy are documented on our website.
557 An HTML version of the GNUnet manual is deployed at
559 https://docs.gnunet.org
561 which currently displays just GNUnet documentation. In the future
562 we will add more reading material.
566 In almost 20 years various people in our community have written and
567 collected a good number of papers which have been implemented in
568 GNUnet or projects around GNUnet.
569 There are currently 2 ways to get them:
571 * Using git (NOTE: 1.1 GiB as of 2019-03-09):
572 git clone https://git.gnunet.org/bibliography.git
573 * Using the webbrowser:
574 https://bib.gnunet.org/
580 * https://gnunet.org/
581 * https://bugs.gnunet.org
582 * https://git.gnunet.org
583 * http://www.gnu.org/software/gnunet/
584 * http://mail.gnu.org/mailman/listinfo/gnunet-developers
585 * http://mail.gnu.org/mailman/listinfo/help-gnunet
586 * http://mail.gnu.org/mailman/listinfo/info-gnunet
587 * http://mail.gnu.org/mailman/listinfo/gnunet-svn