implementing #1747
authorChristian Grothoff <christian@grothoff.org>
Thu, 3 Nov 2011 13:19:52 +0000 (13:19 +0000)
committerChristian Grothoff <christian@grothoff.org>
Thu, 3 Nov 2011 13:19:52 +0000 (13:19 +0000)
57 files changed:
README
contrib/Makefile.am
contrib/defaults.conf [deleted file]
contrib/test_gnunet_prefix.c
src/arm/Makefile.am
src/arm/arm.conf [new file with mode: 0644]
src/ats/Makefile.am
src/ats/ats.conf [new file with mode: 0644]
src/block/Makefile.am
src/block/block.conf [new file with mode: 0644]
src/chat/Makefile.am
src/chat/chat.conf [new file with mode: 0644]
src/core/Makefile.am
src/core/core.conf [new file with mode: 0644]
src/core/test_core_defaults.conf
src/datacache/Makefile.am
src/datacache/datacache.conf [new file with mode: 0644]
src/datastore/Makefile.am
src/datastore/datastore.conf [new file with mode: 0644]
src/datastore/test_defaults.conf
src/dht/Makefile.am
src/dht/dht.conf [new file with mode: 0644]
src/dv/Makefile.am
src/dv/dv.conf [new file with mode: 0644]
src/fs/Makefile.am
src/fs/fs.conf [new file with mode: 0644]
src/fs/test_fs_defaults.conf
src/hostlist/Makefile.am
src/hostlist/hostlist.conf [new file with mode: 0644]
src/hostlist/test_hostlist_defaults.conf
src/mesh/Makefile.am
src/mesh/mesh.conf [new file with mode: 0644]
src/nat/Makefile.am
src/nat/nat.conf [new file with mode: 0644]
src/nse/Makefile.am
src/nse/nse.conf [new file with mode: 0644]
src/peerinfo/Makefile.am
src/peerinfo/peerinfo.conf [new file with mode: 0644]
src/statistics/Makefile.am
src/statistics/statistics.conf [new file with mode: 0644]
src/template/Makefile.am
src/template/template.conf [new file with mode: 0644]
src/testing/Makefile.am
src/testing/test_testing_defaults.conf
src/testing/testing.conf [new file with mode: 0644]
src/topology/Makefile.am
src/topology/topology.conf [new file with mode: 0644]
src/transport/Makefile.am
src/transport/test_transport_defaults.conf
src/transport/transport.conf [new file with mode: 0644]
src/util/Makefile.am
src/util/configuration.c
src/util/disk.c
src/util/resolver.conf [new file with mode: 0644]
src/util/util.conf [new file with mode: 0644]
src/vpn/Makefile.am
src/vpn/vpn.conf [new file with mode: 0644]

diff --git a/README b/README
index 978ae2916d67cd788cd2dd77401483134623a21b..7c6470b267dd7e362d4404086e1bc4e48011a3bf 100644 (file)
--- a/README
+++ b/README
@@ -123,8 +123,8 @@ The defaults that are shipped with the installation are usually ok,
 you may want to adjust the limitations (space consumption, bandwidth,
 etc.) though.  The configuration files are human-readable.  Note that
 you MUST create "~/.gnunet/gnunet.conf" explicitly before starting
-GNUnet.  You can either copy "defaults.conf" or simply create an empty
-file.
+GNUnet.  You can either run gnunet-setup (available as part of the
+gnunet-gtk source package) or simply create an empty file.
 
 
 Usage
index 5efbe5a32b6f556f36816e9614b71733c4bf0f18..0ee7c4922b040f89459ae68837bf992a80260427 100644 (file)
@@ -14,8 +14,7 @@ noinst_SCRIPTS = \
  gnunet_janitor.py
 
 dist_pkgdata_DATA = \
- gnunet-logo-color.png \
- defaults.conf
+ gnunet-logo-color.png 
 
 EXTRA_DIST = \
  coverage.sh \
diff --git a/contrib/defaults.conf b/contrib/defaults.conf
deleted file mode 100644 (file)
index 25bbf53..0000000
+++ /dev/null
@@ -1,505 +0,0 @@
-[PATHS]
-SERVICEHOME = ~/.gnunet/
-# SERVICEHOME = /var/lib/gnunet/
-# DEFAULTCONFIG = /etc/gnunet.conf
-# If 'DEFAULTCONFIG' is not defined, the current
-# configuration file is assumed to be the default,
-# which is what we want by default...
-
-[gnunetd]
-HOSTKEY = $SERVICEHOME/.hostkey
-
-[TESTING]
-WEAKRANDOM = NO
-# How long before failing a connection?
-CONNECT_TIMEOUT = 30
-# How many connect attempts should we make?
-CONNECT_ATTEMPTS = 3
-# How many connections can happen simultaneously?
-MAX_OUTSTANDING_CONNECTIONS = 50
-
-# Should we clean up the files on peer group shutdown?
-DELETE_FILES = YES
-
-[client]
-HOME = $SERVICEHOME
-
-[nat]
-# Are we behind NAT?
-BEHIND_NAT = NO
-
-# Is the NAT hole-punched?
-PUNCHED_NAT = NO
-
-# Enable UPNP by default?
-ENABLE_UPNP = NO
-
-# Use addresses from the local network interfaces (inluding loopback, but also others)
-USE_LOCALADDR = YES
-
-# Use address obtained from a DNS lookup of our hostname
-USE_HOSTNAME = NO
-
-# External IP address of the NAT box (if known); IPv4 dotted-decimal ONLY at this time (should allow DynDNS!)
-# normal interface IP address for non-NATed peers; 
-# possibly auto-detected (using UPnP) if possible if not specified
-# EXTERNAL_ADDRESS = 
-
-# Should we use ICMP-based NAT traversal to try connect to NATed peers
-# or, if we are behind NAT, to allow connections to us?
-ENABLE_ICMP_CLIENT = NO
-ENABLE_ICMP_SERVER = NO
-
-# IP address of the interface connected to the NAT box; IPv4 dotted-decimal ONLY;
-# normal interface IP address for non-NATed peers; 
-# likely auto-detected (via interface list) if not specified (!)
-# INTERNAL_ADDRESS = 
-
-# Disable IPv6 support
-DISABLEV6 = NO
-
-# How often do we query the DNS resolver
-# for our hostname (to get our own IP), in ms
-HOSTNAME_DNS_FREQUENCY = 1200000
-
-# How often do we iterate over our 
-# network interfaces to check for changes
-# in our IP address? in ms
-IFC_SCAN_FREQUENCY = 3000000
-
-# How often do we query the DNS resolver
-# for our hostname (to get our own IP), in ms
-DYNDNS_FREQUENCY = 140000
-
-# Do we use addresses from localhost address ranges? (::1, 127.0.0.0/8)
-RETURN_LOCAL_ADDRESSES = NO
-
-[gnunet-nat-server]
-HOSTNAME = gnunet.org
-PORT = 5724
-
-[transport-tcp]
-# Use 0 to ONLY advertise as a peer behind NAT (no port binding)
-PORT = 2086
-ADVERTISED_PORT = 2086
-
-# Maximum number of open TCP connections allowed
-MAX_CONNECTIONS = 128
-
-TIMEOUT = 5000
-
-# ACCEPT_FROM =
-# ACCEPT_FROM6 =
-# REJECT_FROM =
-# REJECT_FROM6 =
-# BINDTO =
-
-MAX_CONNECTIONS = 128
-
-
-[transport-udp]
-PORT = 2086
-#BROADCAST = YES
-#BROADCAST_PORT = 20089
-#BROADCAST_INTERVAL = 30000
-
-
-MAX_BPS = 1000000
-
-
-[transport-http]
-PORT = 1080
-MAX_CONNECTIONS = 128
-
-[transport-https]
-PORT = 4433
-CRYPTO_INIT = NORMAL
-KEY_FILE = https.key
-CERT_FILE = https.cert
-MAX_CONNECTIONS = 128
-
-
-[transport-wlan]
-# Name of the interface in monitor mode (typically monX)
-INTERFACE = mon0
-# Real hardware, no testing
-TESTMODE = 0
-
-
-[arm]
-PORT = 2087
-HOSTNAME = localhost
-HOME = $SERVICEHOME
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-service-arm
-ACCEPT_FROM = 127.0.0.1;
-ACCEPT_FROM6 = ::1;
-DEFAULTSERVICES = topology hostlist
-UNIXPATH = /tmp/gnunet-service-arm.sock
-UNIX_MATCH_UID = YES
-UNIX_MATCH_GID = YES
-# GLOBAL_POSTFIX = -l $SERVICEHOME/{}-logs
-# GLOBAL_PREFIX =
-# USERNAME =
-# MAXBUF =
-# TIMEOUT =
-# DISABLEV6 =
-# BINDTO =
-# REJECT_FROM =
-# REJECT_FROM6 =
-# PREFIX =
-
-[statistics]
-AUTOSTART = YES
-PORT = 2088
-HOSTNAME = localhost
-HOME = $SERVICEHOME
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-service-statistics
-ACCEPT_FROM = 127.0.0.1;
-ACCEPT_FROM6 = ::1;
-UNIXPATH = /tmp/gnunet-service-statistics.sock
-UNIX_MATCH_UID = NO
-UNIX_MATCH_GID = YES
-# DISABLE_SOCKET_FORWARDING = NO
-# USERNAME = 
-# MAXBUF =
-# TIMEOUT =
-# DISABLEV6 =
-# BINDTO =
-# REJECT_FROM =
-# REJECT_FROM6 =
-# PREFIX =
-
-[resolver]
-AUTOSTART = YES
-PORT = 2089
-HOSTNAME = localhost
-HOME = $SERVICEHOME
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-service-resolver
-ACCEPT_FROM = 127.0.0.1;
-ACCEPT_FROM6 = ::1;
-UNIXPATH = /tmp/gnunet-service-resolver.sock
-UNIX_MATCH_UID = NO
-UNIX_MATCH_GID = NO
-# DISABLE_SOCKET_FORWARDING = NO
-# USERNAME = 
-# MAXBUF =
-# TIMEOUT =
-# DISABLEV6 =
-# BINDTO =
-# REJECT_FROM =
-# REJECT_FROM6 =
-# PREFIX =
-
-[peerinfo]
-AUTOSTART = YES
-PORT = 2090
-HOSTNAME = localhost
-HOME = $SERVICEHOME
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-service-peerinfo
-ACCEPT_FROM = 127.0.0.1;
-ACCEPT_FROM6 = ::1;
-UNIXPATH = /tmp/gnunet-service-peerinfo.sock
-UNIX_MATCH_UID = NO
-UNIX_MATCH_GID = YES
-# DISABLE_SOCKET_FORWARDING = NO
-# USERNAME = 
-# MAXBUF =
-# TIMEOUT =
-# DISABLEV6 =
-# BINDTO = 
-# REJECT_FROM =
-# REJECT_FROM6 =
-# PREFIX =
-HOSTS = $SERVICEHOME/data/hosts/
-
-
-[transport]
-AUTOSTART = YES
-PORT = 2091
-HOSTNAME = localhost
-HOME = $SERVICEHOME
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-service-transport
-#PREFIX = valgrind
-NEIGHBOUR_LIMIT = 50
-ACCEPT_FROM = 127.0.0.1;
-ACCEPT_FROM6 = ::1;
-PLUGINS = tcp
-UNIXPATH = /tmp/gnunet-service-transport.sock
-BLACKLIST_FILE = $SERVICEHOME/blacklist
-UNIX_MATCH_UID = YES
-UNIX_MATCH_GID = YES
-# DISABLE_SOCKET_FORWARDING = NO
-# USERNAME = 
-# MAXBUF =
-# TIMEOUT =
-# DISABLEV6 =
-# BINDTO =
-# REJECT_FROM =
-# REJECT_FROM6 =
-# PREFIX =
-
-[ats]
-AUTOSTART = YES
-PORT = 2098
-HOSTNAME = localhost
-HOME = $SERVICEHOME
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-service-ats
-ACCEPT_FROM = 127.0.0.1;
-ACCEPT_FROM6 = ::1;
-UNIXPATH = /tmp/gnunet-service-ats.sock
-UNIX_MATCH_UID = YES
-UNIX_MATCH_GID = YES
-
-TOTAL_QUOTA_IN = 65536
-TOTAL_QUOTA_OUT = 65536
-# ATS options
-DUMP_MLP = NO
-DUMP_SOLUTION = NO
-DUMP_OVERWRITE = NO 
-DUMP_MIN_PEERS = 0
-DUMP_MIN_ADDRS = 0
-DUMP_OVERWRITE = NO
-ATS_MIN_INTERVAL = 15000
-ATS_EXEC_INTERVAL = 30000
-
-
-[core]
-AUTOSTART = YES
-PORT = 2092
-HOSTNAME = localhost
-HOME = $SERVICEHOME
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-service-core
-ACCEPT_FROM = 127.0.0.1;
-ACCEPT_FROM6 = ::1;
-# quotas are in bytes per second now!
-TOTAL_QUOTA_IN = 65536
-TOTAL_QUOTA_OUT = 65536
-UNIXPATH = /tmp/gnunet-service-core.sock
-UNIX_MATCH_UID = YES
-UNIX_MATCH_GID = YES
-# DISABLE_SOCKET_FORWARDING = NO
-# DEBUG = YES
-# USERNAME = 
-# MAXBUF =
-# TIMEOUT =
-# DISABLEV6 =
-# BINDTO =
-# REJECT_FROM =
-# REJECT_FROM6 =
-# PREFIX =
-
-
-[topology]
-MINIMUM-FRIENDS = 0
-FRIENDS-ONLY = NO
-AUTOCONNECT = YES
-TARGET-CONNECTION-COUNT = 16
-FRIENDS = $SERVICEHOME/friends
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-daemon-topology
-
-[hostlist]
-# port for hostlist http server
-HTTPPORT = 8080
-HOME = $SERVICEHOME
-HOSTLISTFILE = $SERVICEHOME/hostlist/learned.data
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-daemon-hostlist
-# consider having "-e" as default as well once implemented
-OPTIONS = -b
-SERVERS = http://v9.gnunet.org:58080/
-# proxy for downloading hostlists
-HTTP-PROXY = 
-
-
-[datastore]
-AUTOSTART = YES
-UNIXPATH = /tmp/gnunet-service-datastore.sock
-UNIX_MATCH_UID = YES
-UNIX_MATCH_GID = YES
-PORT = 2093
-HOSTNAME = localhost
-HOME = $SERVICEHOME
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-service-datastore
-ACCEPT_FROM = 127.0.0.1;
-ACCEPT_FROM6 = ::1;
-QUOTA = 100000000
-BLOOMFILTER = $SERVICEHOME/fs/bloomfilter
-DATABASE = sqlite
-# DISABLE_SOCKET_FORWARDING = NO
-
-[datastore-sqlite]
-FILENAME = $SERVICEHOME/datastore/sqlite.db
-
-[datastore-postgres]
-CONFIG = connect_timeout=10; dbname=gnunet
-
-[datastore-mysql]
-DATABASE = gnunet
-CONFIG = ~/.my.cnf
-# USER = gnunet
-# PASSWORD = 
-# HOST = localhost
-# PORT = 3306
-
-[datacache-mysql]
-DATABASE = gnunetcheck
-CONFIG = ~/.my.cnf
-# USER = gnunet
-# PASSWORD =
-# HOST = localhost
-# PORT = 3306
-
-
-[fs]
-AUTOSTART = YES
-INDEXDB = $SERVICEHOME/idxinfo.lst
-TRUST = $SERVICEHOME/data/credit/
-IDENTITY_DIR = $SERVICEHOME/identities/
-STATE_DIR = $SERVICEHOME/persistence/
-UPDATE_DIR = $SERVICEHOME/updates/
-PORT = 2094
-HOSTNAME = localhost
-HOME = $SERVICEHOME
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-service-fs
-ACCEPT_FROM = 127.0.0.1;
-ACCEPT_FROM6 = ::1;
-
-DELAY = YES
-CONTENT_CACHING = YES
-CONTENT_PUSHING = YES
-
-UNIXPATH = /tmp/gnunet-service-fs.sock
-UNIX_MATCH_UID = NO
-UNIX_MATCH_GID = YES
-# DISABLE_SOCKET_FORWARDING = NO
-# DEBUG = YES
-MAX_PENDING_REQUESTS = 65536
-# Maximum frequency we're allowed to poll the datastore
-# for content for migration (can be used to reduce 
-# GNUnet's disk-IO rate)
-MIN_MIGRATION_DELAY = 100
-EXPECTED_NEIGHBOUR_COUNT = 128
-
-[dht]
-AUTOSTART = YES
-PORT = 2095
-HOSTNAME = localhost
-HOME = $SERVICEHOME
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-service-dht
-ACCEPT_FROM = 127.0.0.1;
-ACCEPT_FROM6 = ::1;
-BUCKET_SIZE = 4
-UNIXPATH = /tmp/gnunet-service-dht.sock
-UNIX_MATCH_UID = YES
-UNIX_MATCH_GID = YES
-# DISABLE_SOCKET_FORWARDING = NO
-# DEBUG = YES
-# USERNAME = 
-# MAXBUF =
-# TIMEOUT =
-# DISABLEV6 =
-# BINDTO =
-# REJECT_FROM =
-# REJECT_FROM6 =
-# PREFIX =
-# DO_FIND_PEER =
-# STRICT_KADEMLIA =
-# USE_MAX_HOPS =
-# MAX_HOPS =
-# REPUBLISH = YES
-# REPLICATION_FREQUENCY = 60 
-# STOP_ON_CLOSEST =
-# STOP_FOUND =
-# CONVERGE_MODIFIER =
-
-
-[dhtcache]
-DATABASE = sqlite
-QUOTA = 1024000
-
-[block]
-PLUGINS = fs dht test dns
-
-[mesh]
-AUTOSTART = YES
-PORT = 2096
-HOSTNAME = localhost
-HOME = $SERVICEHOME
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-service-mesh
-ACCEPT_FROM = 127.0.0.1;
-ACCEPT_FROM6 = ::1;
-UNIXPATH = /tmp/gnunet-service-mesh.sock
-UNIX_MATCH_UID = YES
-UNIX_MATCH_GID = YES
-
-[nse]
-AUTOSTART = YES
-PORT = 2097
-HOSTNAME = localhost
-HOME = $SERVICEHOME
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-service-nse
-ACCEPT_FROM = 127.0.0.1;
-ACCEPT_FROM6 = ::1;
-UNIXPATH = /tmp/test-nse-service-nse.unix
-UNIX_MATCH_UID = YES
-UNIX_MATCH_GID = YES
-PROOFFILE = $SERVICEHOME/.nse-proof
-HISTOGRAM = $SERVICEHOME/nse-history.log
-
-# How 'slowly' should the proof-of-work be constructed (delay
-# between rounds in ms); sane values between 0 and ~1000.
-WORKDELAY = 5
-
-# Note: changing any of the values below will make this peer
-# completely incompatible with other peers! 
-INTERVAL = 3600000
-WORKBITS = 20
-
-
-[vpn]
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-daemon-vpn
-IPV6ADDR = 1234::1
-IPV6PREFIX = 32
-IPV4ADDR = 10.11.10.1
-IPV4MASK = 255.255.0.0
-VIRTDNS = 10.11.10.2
-VIRTDNS6 = 1234::17
-IFNAME = vpn-gnunet
-
-[exit]
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-daemon-exit
-IPV6ADDR = 1234:1::1
-IPV6PREFIX = 32
-IPV4ADDR = 10.10.1.1
-IPV4MASK = 255.255.0.0
-IFNAME = exit-gnunet
-ENABLE_UDP = NO
-ENABLE_TCP = NO
-
-[dns]
-AUTOSTART = YES
-PORT = 0
-HOSTNAME = localhost
-HOME = $SERVICEHOME
-CONFIG = $DEFAULTCONFIG
-BINARY = gnunet-service-dns
-ACCEPT_FROM = 127.0.0.1;
-ACCEPT_FROM6 = ::1;
-UNIXPATH = /tmp/gnunet-service-dns.sock
-PROVIDE_EXIT = NO
-
index ea81371070709d36165ec2048b2de1c751c20354..732e8ebac4a5c50b6266cecf32c36dc0cc074e08 100644 (file)
@@ -43,7 +43,7 @@ main (int argc,
             _("Testcases will not work!\n"));
     return 1;
   }
-  dirname = DIR_SEPARATOR_STR "share" DIR_SEPARATOR_STR "gnunet" DIR_SEPARATOR_STR "defaults.conf";
+  dirname = DIR_SEPARATOR_STR "share" DIR_SEPARATOR_STR "gnunet" DIR_SEPARATOR_STR "config.d";
   {
     char tmp[strlen (basename) + strlen (dirname) + 1];
     sprintf (tmp, "%s%s", basename, dirname);
index bd6e7e0e75e3178f9f257310eadb15eb38be3bff..9ed8bbe159cf7ee901386f83989670e696c45855 100644 (file)
@@ -1,5 +1,10 @@
 INCLUDES = -I$(top_srcdir)/src/include
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  arm.conf
+
 if MINGW
  WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols 
 endif
diff --git a/src/arm/arm.conf b/src/arm/arm.conf
new file mode 100644 (file)
index 0000000..beb3d30
--- /dev/null
@@ -0,0 +1,23 @@
+
+[arm]
+PORT = 2087
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-arm
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+DEFAULTSERVICES = topology hostlist
+UNIXPATH = /tmp/gnunet-service-arm.sock
+UNIX_MATCH_UID = YES
+UNIX_MATCH_GID = YES
+# GLOBAL_POSTFIX = -l $SERVICEHOME/{}-logs
+# GLOBAL_PREFIX =
+# USERNAME =
+# MAXBUF =
+# TIMEOUT =
+# DISABLEV6 =
+# BINDTO =
+# REJECT_FROM =
+# REJECT_FROM6 =
+# PREFIX =
\ No newline at end of file
index 5cba4fccb105f9ad5d81b5761673b6af0175b4c1..0db590a81a81230bba0eee7007eaaa9eedaac654 100644 (file)
@@ -1,5 +1,10 @@
 INCLUDES = -I$(top_srcdir)/src/include
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  ats.conf
+
 if MINGW
  WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols 
 endif
diff --git a/src/ats/ats.conf b/src/ats/ats.conf
new file mode 100644 (file)
index 0000000..f5d6c77
--- /dev/null
@@ -0,0 +1,24 @@
+[ats]
+AUTOSTART = YES
+PORT = 2098
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-ats
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+UNIXPATH = /tmp/gnunet-service-ats.sock
+UNIX_MATCH_UID = YES
+UNIX_MATCH_GID = YES
+
+TOTAL_QUOTA_IN = 65536
+TOTAL_QUOTA_OUT = 65536
+# ATS options
+DUMP_MLP = NO
+DUMP_SOLUTION = NO
+DUMP_OVERWRITE = NO 
+DUMP_MIN_PEERS = 0
+DUMP_MIN_ADDRS = 0
+DUMP_OVERWRITE = NO
+ATS_MIN_INTERVAL = 15000
+ATS_EXEC_INTERVAL = 30000
index 45229661365eecdea01dd31b69627bcdd8205b07..96b66c3eebfa6a205959ba06e49917f78c6b5454 100644 (file)
@@ -2,6 +2,11 @@ INCLUDES = -I$(top_srcdir)/src/include
 
 plugindir = $(libdir)/gnunet
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  block.conf
+
 if MINGW
   WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols
 endif
diff --git a/src/block/block.conf b/src/block/block.conf
new file mode 100644 (file)
index 0000000..dbae438
--- /dev/null
@@ -0,0 +1,2 @@
+[block]
+PLUGINS = fs dht test dns
\ No newline at end of file
index dcf1f5a2d586141239359d14317503ed87d9259a..859e8f1f1c1de7128a0173d5096ce69139fbd59a 100644 (file)
@@ -1,5 +1,10 @@
 INCLUDES = -I$(top_srcdir)/src/include
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  chat.conf
+
 if MINGW
  WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols 
 endif
diff --git a/src/chat/chat.conf b/src/chat/chat.conf
new file mode 100644 (file)
index 0000000..61d551e
--- /dev/null
@@ -0,0 +1,22 @@
+[chat]
+AUTOSTART = YES
+PORT = 2090
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-chat
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+UNIXPATH = /tmp/gnunet-service-chat.sock
+UNIX_MATCH_UID = NO
+UNIX_MATCH_GID = YES
+# DISABLE_SOCKET_FORWARDING = NO
+# USERNAME = 
+# MAXBUF =
+# TIMEOUT =
+# DISABLEV6 =
+# BINDTO = 
+# REJECT_FROM =
+# REJECT_FROM6 =
+# PREFIX =
+
index b2629a567b71b00d137c518ba0022572a7b02e06..13054d15a39af642355baeed2091810c9bb17d7e 100644 (file)
@@ -1,5 +1,10 @@
 INCLUDES = -I$(top_srcdir)/src/include
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  core.conf
+
 if MINGW
   WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols
 endif
diff --git a/src/core/core.conf b/src/core/core.conf
new file mode 100644 (file)
index 0000000..1d7815a
--- /dev/null
@@ -0,0 +1,25 @@
+[core]
+AUTOSTART = YES
+PORT = 2092
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-core
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+# quotas are in bytes per second now!
+TOTAL_QUOTA_IN = 65536
+TOTAL_QUOTA_OUT = 65536
+UNIXPATH = /tmp/gnunet-service-core.sock
+UNIX_MATCH_UID = YES
+UNIX_MATCH_GID = YES
+# DISABLE_SOCKET_FORWARDING = NO
+# DEBUG = YES
+# USERNAME = 
+# MAXBUF =
+# TIMEOUT =
+# DISABLEV6 =
+# BINDTO =
+# REJECT_FROM =
+# REJECT_FROM6 =
+# PREFIX =
index 5d8da2d34a4df64d65a723c419872ed8b676529d..b3b74509589b38560a894105406d57bf4836407a 100644 (file)
@@ -43,3 +43,6 @@ AUTOSTART = NO
 
 [nse]
 AUTOSTART = NO
+
+[dv]
+AUTOSTART = NO
\ No newline at end of file
index 8e4f265cdbd76feb4e7f550de26014c28b28c9a6..5a3d22bbb8b7df46ba73132b8d5fcdd9651c9980 100644 (file)
@@ -2,6 +2,11 @@ INCLUDES = -I$(top_srcdir)/src/include
 
 plugindir = $(libdir)/gnunet
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  datacache.conf
+
 if MINGW
   WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols
 endif
diff --git a/src/datacache/datacache.conf b/src/datacache/datacache.conf
new file mode 100644 (file)
index 0000000..fb850f3
--- /dev/null
@@ -0,0 +1,8 @@
+[datacache-mysql]
+DATABASE = gnunetcheck
+CONFIG = ~/.my.cnf
+# USER = gnunet
+# PASSWORD =
+# HOST = localhost
+# PORT = 3306
+
index cecda89b43b3a4cedd5333bda27ce49e8bb69b62..cab08bc0fb782ca3db6b72fc2242b69004cc9070 100644 (file)
@@ -2,6 +2,11 @@ INCLUDES = -I$(top_srcdir)/src/include
 
 plugindir = $(libdir)/gnunet
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  datastore.conf
+
 if MINGW
   WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols
 endif
diff --git a/src/datastore/datastore.conf b/src/datastore/datastore.conf
new file mode 100644 (file)
index 0000000..ed44036
--- /dev/null
@@ -0,0 +1,33 @@
+[datastore]
+AUTOSTART = YES
+UNIXPATH = /tmp/gnunet-service-datastore.sock
+UNIX_MATCH_UID = YES
+UNIX_MATCH_GID = YES
+PORT = 2093
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-datastore
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+QUOTA = 100000000
+BLOOMFILTER = $SERVICEHOME/fs/bloomfilter
+DATABASE = sqlite
+# DISABLE_SOCKET_FORWARDING = NO
+
+[datastore-sqlite]
+FILENAME = $SERVICEHOME/datastore/sqlite.db
+
+[datastore-postgres]
+CONFIG = connect_timeout=10; dbname=gnunet
+
+[datastore-mysql]
+DATABASE = gnunet
+CONFIG = ~/.my.cnf
+# USER = gnunet
+# PASSWORD = 
+# HOST = localhost
+# PORT = 3306
+
+
+
index 2af5c53152b29385b67c19d7c5ca43a3767dd0bc..e2911fc2d5694945468d42011135721383833d86 100644 (file)
@@ -13,3 +13,6 @@ AUTOSTART = NO
 
 [nse]
 AUTOSTART = NO
+
+[dv]
+AUTOSTART = NO
\ No newline at end of file
index 952e828d3434cbd41e1346ece2e28779d569ce81..ad1d05d25fb2df798785e5fde5cbaa10c9a2622a 100644 (file)
@@ -5,6 +5,11 @@ endif
 
 plugindir = $(libdir)/gnunet
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  dht.conf 
+
 if HAVE_ZLIB
  ZLIB_LNK = -lz
 endif
diff --git a/src/dht/dht.conf b/src/dht/dht.conf
new file mode 100644 (file)
index 0000000..50c25da
--- /dev/null
@@ -0,0 +1,38 @@
+[dht]
+AUTOSTART = YES
+PORT = 2095
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-dht
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+BUCKET_SIZE = 4
+UNIXPATH = /tmp/gnunet-service-dht.sock
+UNIX_MATCH_UID = YES
+UNIX_MATCH_GID = YES
+# DISABLE_SOCKET_FORWARDING = NO
+# DEBUG = YES
+# USERNAME = 
+# MAXBUF =
+# TIMEOUT =
+# DISABLEV6 =
+# BINDTO =
+# REJECT_FROM =
+# REJECT_FROM6 =
+# PREFIX =
+# DO_FIND_PEER =
+# STRICT_KADEMLIA =
+# USE_MAX_HOPS =
+# MAX_HOPS =
+# REPUBLISH = YES
+# REPLICATION_FREQUENCY = 60 
+# STOP_ON_CLOSEST =
+# STOP_FOUND =
+# CONVERGE_MODIFIER =
+
+
+[dhtcache]
+DATABASE = sqlite
+QUOTA = 1024000
+
index d505e31c41a0c8d0b9e674b54728932c2410f429..c0e826a2ca8035fc424ac0bb2f02adb2fafdd0e8 100644 (file)
@@ -11,6 +11,11 @@ endif
 
 plugindir = $(libdir)/gnunet
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  dv.conf
+
 lib_LTLIBRARIES = libgnunetdv.la
 
 plugin_LTLIBRARIES = libgnunet_plugin_transport_dv.la
diff --git a/src/dv/dv.conf b/src/dv/dv.conf
new file mode 100644 (file)
index 0000000..8fbf236
--- /dev/null
@@ -0,0 +1,15 @@
+[dv]
+AUTOSTART = YES
+DEBUG = NO
+ACCEPT_FROM6 = ::1;
+ACCEPT_FROM = 127.0.0.1;
+BINARY = gnunet-service-dv
+CONFIG = $DEFAULTCONFIG
+HOME = $SERVICEHOME
+HOSTNAME = localhost
+PORT = 2571
+# ACCEPT_FROM =
+# ACCEPT_FROM6 =
+# REJECT_FROM =
+# REJECT_FROM6 =
+# BINDTO =
index 85e3a4539a9c4484c8a4e89efd462772bbc24c29..3e94e91826ab4ae2c574d57127810a61a08bf219 100644 (file)
@@ -9,6 +9,11 @@ if USE_COVERAGE
   XLIB = -lgcov
 endif
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  fs.conf
+
 
 lib_LTLIBRARIES = libgnunetfs.la
 
diff --git a/src/fs/fs.conf b/src/fs/fs.conf
new file mode 100644 (file)
index 0000000..7e3fecd
--- /dev/null
@@ -0,0 +1,32 @@
+[fs]
+AUTOSTART = YES
+INDEXDB = $SERVICEHOME/idxinfo.lst
+TRUST = $SERVICEHOME/data/credit/
+IDENTITY_DIR = $SERVICEHOME/identities/
+STATE_DIR = $SERVICEHOME/persistence/
+UPDATE_DIR = $SERVICEHOME/updates/
+PORT = 2094
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-fs
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+
+DELAY = YES
+CONTENT_CACHING = YES
+CONTENT_PUSHING = YES
+
+UNIXPATH = /tmp/gnunet-service-fs.sock
+UNIX_MATCH_UID = NO
+UNIX_MATCH_GID = YES
+# DISABLE_SOCKET_FORWARDING = NO
+# DEBUG = YES
+MAX_PENDING_REQUESTS = 65536
+# Maximum frequency we're allowed to poll the datastore
+# for content for migration (can be used to reduce 
+# GNUnet's disk-IO rate)
+MIN_MIGRATION_DELAY = 100
+EXPECTED_NEIGHBOUR_COUNT = 128
+
+
index 5e54e15ea1e62509d578d5c77f20d30d20100937..f71a1206185db473c205df561c501534bc60fc26 100644 (file)
@@ -71,3 +71,6 @@ AUTOSTART = NO
 
 [nse]
 AUTOSTART = NO
+
+[dv]
+AUTOSTART = NO
\ No newline at end of file
index 8af1d4a7fedda00fca2409d4880194ab457e8f01..f764f2fbe7a26aa0bb71efb84b223a5fa039cad7 100644 (file)
@@ -1,5 +1,10 @@
 INCLUDES = -I$(top_srcdir)/src/include
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  hostlist.conf
+
 if USE_COVERAGE
   AM_CFLAGS = --coverage -O0
 endif
diff --git a/src/hostlist/hostlist.conf b/src/hostlist/hostlist.conf
new file mode 100644 (file)
index 0000000..3f8c142
--- /dev/null
@@ -0,0 +1,14 @@
+[hostlist]
+# port for hostlist http server
+HTTPPORT = 8080
+HOME = $SERVICEHOME
+HOSTLISTFILE = $SERVICEHOME/hostlist/learned.data
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-daemon-hostlist
+# consider having "-e" as default as well once implemented
+OPTIONS = -b
+SERVERS = http://v9.gnunet.org:58080/
+# proxy for downloading hostlists
+HTTP-PROXY = 
+
+
index 473ac2a95c9ff60a8bce84f1b9bf57bf04037eff..08c58b963ed2b4d64848537e1eb6fb7205d40886 100644 (file)
@@ -48,3 +48,6 @@ AUTOSTART = NO
 
 [dht]
 AUTOSTART = NO
+
+[dv]
+AUTOSTART = NO
\ No newline at end of file
index bfec0d5b445741c9a1378300baa0e96a2c56919f..f6546a586c73dbc1d22357e3acaa6e7a1164c2c8 100644 (file)
@@ -9,6 +9,11 @@ if USE_COVERAGE
   XLIB = -lgcov
 endif
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  mesh.conf
+
 AM_CLFAGS = -g
 
 bin_PROGRAMS = \
diff --git a/src/mesh/mesh.conf b/src/mesh/mesh.conf
new file mode 100644 (file)
index 0000000..9222753
--- /dev/null
@@ -0,0 +1,13 @@
+[mesh]
+AUTOSTART = YES
+PORT = 2096
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-mesh
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+UNIXPATH = /tmp/gnunet-service-mesh.sock
+UNIX_MATCH_UID = YES
+UNIX_MATCH_GID = YES
+
index 5adab1ae587b9bb32d5990dce47f42d94821b79d..ed3a1545ae5cc281836dbad82cdcc9df3067e4aa 100644 (file)
@@ -7,6 +7,11 @@ if MINGW
   NATCLIENT = gnunet-helper-nat-client-windows.c
 endif
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  nat.conf
+
 
 if ENABLE_TEST_RUN
  nattest = $(bindir)/gnunet-nat-server
diff --git a/src/nat/nat.conf b/src/nat/nat.conf
new file mode 100644 (file)
index 0000000..e446122
--- /dev/null
@@ -0,0 +1,54 @@
+[nat]
+# Are we behind NAT?
+BEHIND_NAT = NO
+
+# Is the NAT hole-punched?
+PUNCHED_NAT = NO
+
+# Enable UPNP by default?
+ENABLE_UPNP = NO
+
+# Use addresses from the local network interfaces (inluding loopback, but also others)
+USE_LOCALADDR = YES
+
+# Use address obtained from a DNS lookup of our hostname
+USE_HOSTNAME = NO
+
+# External IP address of the NAT box (if known); IPv4 dotted-decimal ONLY at this time (should allow DynDNS!)
+# normal interface IP address for non-NATed peers; 
+# possibly auto-detected (using UPnP) if possible if not specified
+# EXTERNAL_ADDRESS = 
+
+# Should we use ICMP-based NAT traversal to try connect to NATed peers
+# or, if we are behind NAT, to allow connections to us?
+ENABLE_ICMP_CLIENT = NO
+ENABLE_ICMP_SERVER = NO
+
+# IP address of the interface connected to the NAT box; IPv4 dotted-decimal ONLY;
+# normal interface IP address for non-NATed peers; 
+# likely auto-detected (via interface list) if not specified (!)
+# INTERNAL_ADDRESS = 
+
+# Disable IPv6 support
+DISABLEV6 = NO
+
+# Do we use addresses from localhost address ranges? (::1, 127.0.0.0/8)
+RETURN_LOCAL_ADDRESSES = NO
+
+# How often do we query the DNS resolver
+# for our hostname (to get our own IP), in ms
+HOSTNAME_DNS_FREQUENCY = 1200000
+
+# How often do we iterate over our 
+# network interfaces to check for changes
+# in our IP address? in ms
+IFC_SCAN_FREQUENCY = 3000000
+
+# How often do we query the DNS resolver
+# for our hostname (to get our own IP), in ms
+DYNDNS_FREQUENCY = 140000
+
+[gnunet-nat-server]
+HOSTNAME = gnunet.org
+PORT = 5724
+
index af16a420de2ba798c717a4e05ae169c3faf05bb9..48844bfc07d244cba98a1380324407466457eda8 100644 (file)
@@ -9,6 +9,11 @@ if USE_COVERAGE
   XLIB = -lgcov
 endif
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  nse.conf
+
 
 lib_LTLIBRARIES = libgnunetnse.la
 
diff --git a/src/nse/nse.conf b/src/nse/nse.conf
new file mode 100644 (file)
index 0000000..318fd15
--- /dev/null
@@ -0,0 +1,24 @@
+[nse]
+AUTOSTART = YES
+PORT = 2097
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-nse
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+UNIXPATH = /tmp/test-nse-service-nse.unix
+UNIX_MATCH_UID = YES
+UNIX_MATCH_GID = YES
+PROOFFILE = $SERVICEHOME/.nse-proof
+HISTOGRAM = $SERVICEHOME/nse-history.log
+
+# How 'slowly' should the proof-of-work be constructed (delay
+# between rounds in ms); sane values between 0 and ~1000.
+WORKDELAY = 5
+
+# Note: changing any of the values below will make this peer
+# completely incompatible with other peers! 
+INTERVAL = 3600000
+WORKBITS = 20
+
index d5842573037ee0439dafe16d91d81d32d6add87a..13a763b476e0a8b2c8a5b52668aa4ee6b7acb295 100644 (file)
@@ -1,5 +1,10 @@
 INCLUDES = -I$(top_srcdir)/src/include
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  peerinfo.conf
+
 if MINGW
  WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols -lole32 -lshell32 -liconv -lstdc++ -lcomdlg32 -lgdi32
 endif
diff --git a/src/peerinfo/peerinfo.conf b/src/peerinfo/peerinfo.conf
new file mode 100644 (file)
index 0000000..1b300ca
--- /dev/null
@@ -0,0 +1,24 @@
+[peerinfo]
+AUTOSTART = YES
+PORT = 2090
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-peerinfo
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+UNIXPATH = /tmp/gnunet-service-peerinfo.sock
+UNIX_MATCH_UID = NO
+UNIX_MATCH_GID = YES
+# DISABLE_SOCKET_FORWARDING = NO
+# USERNAME = 
+# MAXBUF =
+# TIMEOUT =
+# DISABLEV6 =
+# BINDTO = 
+# REJECT_FROM =
+# REJECT_FROM6 =
+# PREFIX =
+HOSTS = $SERVICEHOME/data/hosts/
+
+
index a15aba9fb237b8af000c998a2cec0acaa6ebab2b..80110bbec8db151a61c910e9d808435e7506b559 100644 (file)
@@ -9,6 +9,10 @@ if USE_COVERAGE
   XLIB = -lgcov
 endif
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  statistics.conf
 
 lib_LTLIBRARIES = libgnunetstatistics.la
 
diff --git a/src/statistics/statistics.conf b/src/statistics/statistics.conf
new file mode 100644 (file)
index 0000000..e54c519
--- /dev/null
@@ -0,0 +1,22 @@
+[statistics]
+AUTOSTART = YES
+PORT = 2088
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-statistics
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+UNIXPATH = /tmp/gnunet-service-statistics.sock
+UNIX_MATCH_UID = NO
+UNIX_MATCH_GID = YES
+# DISABLE_SOCKET_FORWARDING = NO
+# USERNAME = 
+# MAXBUF =
+# TIMEOUT =
+# DISABLEV6 =
+# BINDTO =
+# REJECT_FROM =
+# REJECT_FROM6 =
+# PREFIX =
+
index 35a4b433e821511a23ead0a604e9e91672123504..1769191e7a1d965566a865e3de5f661d708755e3 100644 (file)
@@ -1,5 +1,10 @@
 INCLUDES = -I$(top_srcdir)/src/include
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  template.conf
+
 if MINGW
  WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols 
 endif
diff --git a/src/template/template.conf b/src/template/template.conf
new file mode 100644 (file)
index 0000000..522721f
--- /dev/null
@@ -0,0 +1,21 @@
+[template]
+AUTOSTART = NO
+PORT = 9999
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-template
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+UNIXPATH = /tmp/gnunet-service-template.sock
+UNIX_MATCH_UID = YES
+UNIX_MATCH_GID = YES
+# DISABLE_SOCKET_FORWARDING = NO
+# USERNAME = 
+# MAXBUF =
+# TIMEOUT =
+# DISABLEV6 =
+# BINDTO =
+# REJECT_FROM =
+# REJECT_FROM6 =
+# PREFIX =
index 7e594e46ede72589df0e3e53b5a0973fc7fb2f27..88102e112cba7135f467a3ff0e8acf4fa35f1ef6 100644 (file)
@@ -9,6 +9,11 @@ if USE_COVERAGE
   XLIB = -lgcov
 endif
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  testing.conf
+
 if HAVE_EXPENSIVE_TESTS
   EXPENSIVE_TESTS = \
    test_testing_topology_stability \
index 5195882b4f5f1627fa2efdf51169431014db8cd6..c4810c303234bc96fd4b9e5fe9e876d2728c5119 100644 (file)
@@ -58,3 +58,6 @@ AUTOSTART = NO
 
 [fs]
 AUTOSTART = NO
+
+[dv]
+AUTOSTART = NO
diff --git a/src/testing/testing.conf b/src/testing/testing.conf
new file mode 100644 (file)
index 0000000..1604ebc
--- /dev/null
@@ -0,0 +1,11 @@
+[TESTING]
+# How long before failing a connection?
+CONNECT_TIMEOUT = 30
+# How many connect attempts should we make?
+CONNECT_ATTEMPTS = 3
+# How many connections can happen simultaneously?
+MAX_OUTSTANDING_CONNECTIONS = 50
+
+# Should we clean up the files on peer group shutdown?
+DELETE_FILES = YES
+
index 3b69627e35ca018b49046afa0e9eff3556d9f858..261be86190cc8a79cafd04d0da90dcfbc1f4e66e 100644 (file)
@@ -4,6 +4,11 @@ if USE_COVERAGE
   AM_CFLAGS = --coverage -O0
 endif
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  topology.conf
+
 
 bin_PROGRAMS = \
  gnunet-daemon-topology
diff --git a/src/topology/topology.conf b/src/topology/topology.conf
new file mode 100644 (file)
index 0000000..39f2921
--- /dev/null
@@ -0,0 +1,10 @@
+[topology]
+MINIMUM-FRIENDS = 0
+FRIENDS-ONLY = NO
+AUTOCONNECT = YES
+TARGET-CONNECTION-COUNT = 16
+FRIENDS = $SERVICEHOME/friends
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-daemon-topology
+
+
index 110b43cdff8548410cf18a8cbe524e68cbf4fed7..e5230410c2a1d0d5bc9afc8894fd81aee76939e6 100644 (file)
@@ -2,6 +2,11 @@ INCLUDES = -I$(top_srcdir)/src/include -I$(top_builddir)/src/include
 
 plugindir = $(libdir)/gnunet
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  transport.conf
+
 
 if HAVE_MHD
  GN_LIBMHD = -lmicrohttpd
index e2e03a0a9f9f826cf74a2c2f94e0fbdcb0ef2725..60a65dec59b93a817ed2e3d04d9597b766431adc 100644 (file)
@@ -32,6 +32,9 @@ AUTOSTART = NO
 [dns]
 AUTOSTART = NO
 
+[dv]
+AUTOSTART = NO
+
 [nat]
 DISABLEV6 = YES
 BINDTO = 127.0.0.1
diff --git a/src/transport/transport.conf b/src/transport/transport.conf
new file mode 100644 (file)
index 0000000..ded8e30
--- /dev/null
@@ -0,0 +1,66 @@
+[transport]
+AUTOSTART = YES
+PORT = 2091
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-transport
+#PREFIX = valgrind
+NEIGHBOUR_LIMIT = 50
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+PLUGINS = tcp
+UNIXPATH = /tmp/gnunet-service-transport.sock
+BLACKLIST_FILE = $SERVICEHOME/blacklist
+UNIX_MATCH_UID = YES
+UNIX_MATCH_GID = YES
+# DISABLE_SOCKET_FORWARDING = NO
+# USERNAME = 
+# MAXBUF =
+# TIMEOUT =
+# DISABLEV6 =
+# BINDTO =
+# REJECT_FROM =
+# REJECT_FROM6 =
+# PREFIX =
+
+[transport-tcp]
+# Use 0 to ONLY advertise as a peer behind NAT (no port binding)
+PORT = 2086
+ADVERTISED_PORT = 2086
+
+# Maximum number of open TCP connections allowed
+MAX_CONNECTIONS = 128
+
+TIMEOUT = 5000
+# ACCEPT_FROM =
+# ACCEPT_FROM6 =
+# REJECT_FROM =
+# REJECT_FROM6 =
+# BINDTO =
+MAX_CONNECTIONS = 128
+
+[transport-udp]
+PORT = 2086
+#BROADCAST = YES
+#BROADCAST_PORT = 20089
+#BROADCAST_INTERVAL = 30000
+MAX_BPS = 1000000
+
+[transport-http]
+PORT = 1080
+MAX_CONNECTIONS = 128
+
+[transport-https]
+PORT = 4433
+CRYPTO_INIT = NORMAL
+KEY_FILE = https.key
+CERT_FILE = https.cert
+MAX_CONNECTIONS = 128
+
+[transport-wlan]
+# Name of the interface in monitor mode (typically monX)
+INTERFACE = mon0
+# Real hardware, no testing
+TESTMODE = 0
+
index d816bc42c434167037694a0b8b717a57d56a7d0c..98af8383a89298b033b1ff4e43e511111187fe9f 100644 (file)
@@ -2,6 +2,11 @@ INCLUDES = -I$(top_srcdir)/src/include -I$(top_builddir)/src/include
 
 plugindir = $(libdir)/gnunet
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  util.conf resolver.conf
+
 if MINGW
 noinst_LTLIBRARIES = \
   libgnunetutilwin.la
index adfd4ea5aadc43b57b096d6828dfdf142dac6c7f..a269ed0361eada3470552b70089205cfa070c559 100644 (file)
@@ -1214,6 +1214,25 @@ GNUNET_CONFIGURATION_remove_value_filename (struct GNUNET_CONFIGURATION_Handle
 }
 
 
+/**
+ * Wrapper around GNUNET_CONFIGURATION_parse.
+ *
+ * @param cls the cfg
+ * @param filename file to parse
+ * @return GNUNET_OK on success
+ */
+static int
+parse_configuration_file (void *cls,
+                         const char *filename)
+{
+  struct GNUNET_CONFIGURATION_Handle *cfg = cls;
+  int ret;
+
+  ret = GNUNET_CONFIGURATION_parse (cfg, filename);
+  return ret;
+}
+
+
 /**
  * Load configuration (starts with defaults, then loads
  * system-specific configuration).
@@ -1233,17 +1252,24 @@ GNUNET_CONFIGURATION_load (struct GNUNET_CONFIGURATION_Handle *cfg,
   if (ipath == NULL)
     return GNUNET_SYSERR;
   baseconfig = NULL;
-  GNUNET_asprintf (&baseconfig, "%s%s%s", ipath, DIR_SEPARATOR_STR,
-                  "defaults.conf");
+  GNUNET_asprintf (&baseconfig, "%s%s", ipath, 
+                  "config.d");
   GNUNET_free (ipath);
-  if ((GNUNET_OK != GNUNET_CONFIGURATION_parse (cfg, baseconfig)) ||
-      (!((filename == NULL) ||
-        (GNUNET_OK == GNUNET_CONFIGURATION_parse (cfg, filename)))))
-    {
-      GNUNET_free (baseconfig);
-      return (filename == NULL) ? GNUNET_OK : GNUNET_SYSERR;
-    }
-  GNUNET_free (baseconfig);
+  if (GNUNET_SYSERR ==
+      GNUNET_DISK_directory_scan (baseconfig,
+                                 &parse_configuration_file,
+                                 cfg))
+  {
+    GNUNET_free (baseconfig);
+    return GNUNET_SYSERR; /* no configuration at all found */    
+  }
+  GNUNET_free (baseconfig);  
+  if ( (filename != NULL) &&
+       (GNUNET_OK != GNUNET_CONFIGURATION_parse (cfg, filename)) )
+  {
+    /* specified configuration not found */
+    return GNUNET_SYSERR;
+  }
   if (((GNUNET_YES !=
        GNUNET_CONFIGURATION_have_value (cfg, "PATHS", "DEFAULTCONFIG"))) &&
       (filename != NULL))
index 2021d6493a95619b866c79382931bab1ee7d4208..12f985791baaf3e63749707e77bcd899f2ef5620 100644 (file)
@@ -795,6 +795,7 @@ GNUNET_DISK_fn_write (const char *fn, const void *buffer, size_t n,
   return ret;
 }
 
+
 /**
  * Scan a directory for files.
  *
diff --git a/src/util/resolver.conf b/src/util/resolver.conf
new file mode 100644 (file)
index 0000000..a2690fc
--- /dev/null
@@ -0,0 +1,22 @@
+[resolver]
+AUTOSTART = YES
+PORT = 2089
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-resolver
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+UNIXPATH = /tmp/gnunet-service-resolver.sock
+UNIX_MATCH_UID = NO
+UNIX_MATCH_GID = NO
+# DISABLE_SOCKET_FORWARDING = NO
+# USERNAME = 
+# MAXBUF =
+# TIMEOUT =
+# DISABLEV6 =
+# BINDTO =
+# REJECT_FROM =
+# REJECT_FROM6 =
+# PREFIX =
+
diff --git a/src/util/util.conf b/src/util/util.conf
new file mode 100644 (file)
index 0000000..ba9dfec
--- /dev/null
@@ -0,0 +1,16 @@
+[PATHS]
+SERVICEHOME = ~/.gnunet/
+# SERVICEHOME = /var/lib/gnunet/
+# DEFAULTCONFIG = /etc/gnunet.conf
+# If 'DEFAULTCONFIG' is not defined, the current
+# configuration file is assumed to be the default,
+# which is what we want by default...
+
+[gnunetd]
+HOSTKEY = $SERVICEHOME/.hostkey
+
+[client]
+HOME = $SERVICEHOME
+
+[TESTING]
+WEAKRANDOM = NO
index d0abc652208f3c89e4d67c6c5a092733a8d30a5c..c6b390acabe54a2ecbc62fe2384679616429413c 100644 (file)
@@ -8,6 +8,11 @@ if USE_COVERAGE
   AM_CFLAGS = --coverage -O0
 endif
 
+pkgcfgdir= $(pkgdatadir)/config.d/
+
+dist_pkgcfg_DATA = \
+  vpn.conf
+
 if LINUX
 VPNBIN = gnunet-helper-vpn
 HIJACKBIN = gnunet-helper-hijack-dns
diff --git a/src/vpn/vpn.conf b/src/vpn/vpn.conf
new file mode 100644 (file)
index 0000000..0baaa83
--- /dev/null
@@ -0,0 +1,33 @@
+[vpn]
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-daemon-vpn
+IPV6ADDR = 1234::1
+IPV6PREFIX = 32
+IPV4ADDR = 10.11.10.1
+IPV4MASK = 255.255.0.0
+VIRTDNS = 10.11.10.2
+VIRTDNS6 = 1234::17
+IFNAME = vpn-gnunet
+
+[exit]
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-daemon-exit
+IPV6ADDR = 1234:1::1
+IPV6PREFIX = 32
+IPV4ADDR = 10.10.1.1
+IPV4MASK = 255.255.0.0
+IFNAME = exit-gnunet
+ENABLE_UDP = NO
+ENABLE_TCP = NO
+
+[dns]
+AUTOSTART = YES
+PORT = 0
+HOSTNAME = localhost
+HOME = $SERVICEHOME
+CONFIG = $DEFAULTCONFIG
+BINARY = gnunet-service-dns
+ACCEPT_FROM = 127.0.0.1;
+ACCEPT_FROM6 = ::1;
+UNIXPATH = /tmp/gnunet-service-dns.sock
+PROVIDE_EXIT = NO