summaryrefslogtreecommitdiff
path: root/conf
diff options
context:
space:
mode:
Diffstat (limited to 'conf')
-rw-r--r--conf/dnsmasq.conf9
-rw-r--r--conf/interfaces.d_eth028
-rwxr-xr-xconf/network_if-up.d_samizdat5
-rw-r--r--conf/postfix_main.cf43
-rw-r--r--conf/torrc17
5 files changed, 102 insertions, 0 deletions
diff --git a/conf/dnsmasq.conf b/conf/dnsmasq.conf
new file mode 100644
index 0000000..2b523ec
--- /dev/null
+++ b/conf/dnsmasq.conf
@@ -0,0 +1,9 @@
1interface=br0
2domain=localdomain
3dhcp-range=192.168.10.10,192.168.10.253,255.255.255.0,1h
4dhcp-boot=pxelinux.0,pxeserver,192.168.10.1
5pxe-service=x86PC, "Samizdat", pxelinux
6enable-tftp
7tftp-root=/usr/local/lib/samizdat-rhizome/isolinux
8tftp-unique-root
9dhcp-script=/usr/local/bin/dnsmasq-dhcp-script.sh
diff --git a/conf/interfaces.d_eth0 b/conf/interfaces.d_eth0
new file mode 100644
index 0000000..5ec8666
--- /dev/null
+++ b/conf/interfaces.d_eth0
@@ -0,0 +1,28 @@
1# iface eth0 inet static
2# address 192.168.10.1
3# netmask 255.255.255.0
4# # post-up ipsec restart
5
6auto br0 eth0
7
8iface br0 inet static
9 address 192.168.10.1
10 netmask 255.255.255.0
11## These are useful for VMs:
12# pre-up for n in 0 1 2 3 4; do tunctl -t tap$n; done; true
13# pre-down for n in 0 1 2 3 4; do tunctl -d tap$n; done; true
14# bridge_ports eth0 tap0 tap1 tap2 tap3 tap4
15# bridge_maxwait 10
16
17## Enable "internet connection sharing"
18 up iptables -t nat -A POSTROUTING -o wlan0 -j MASQUERADE
19 up sysctl -w net.ipv4.ip_forward=1
20
21## Disable ipv6 auto-address.
22## This is needed sometimes, if ipv6 breaks ipv4.
23# pre-up echo 0 > /proc/sys/net/ipv6/conf/br0/accept_ra_pinfo
24
25# NB. 'ipsec reload' does not work very well
26 post-up ipsec restart
27
28iface eth0 inet manual
diff --git a/conf/network_if-up.d_samizdat b/conf/network_if-up.d_samizdat
new file mode 100755
index 0000000..4c02c93
--- /dev/null
+++ b/conf/network_if-up.d_samizdat
@@ -0,0 +1,5 @@
1#!/bin/sh
2RULE='OUTPUT -p tcp -d 10.192.0.0/10 -j REDIRECT --to-ports 9040'
3iptables -t nat -D $RULE 2>/dev/null
4[ "$VERBOSITY" -gt 0 ] && set -x
5iptables -t nat -A $RULE
diff --git a/conf/postfix_main.cf b/conf/postfix_main.cf
new file mode 100644
index 0000000..7e11ff1
--- /dev/null
+++ b/conf/postfix_main.cf
@@ -0,0 +1,43 @@
1# See /usr/share/postfix/main.cf.dist for a commented, more complete version
2
3
4# Debian specific: Specifying a file name will cause the first
5# line of that file to be used as the name. The Debian default
6# is /etc/mailname.
7myorigin = /etc/mailname
8
9smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU)
10biff = yes
11
12# appending .domain is the MUA's job.
13append_dot_mydomain = no
14
15# It's 2013; we expect mail to be delivered quickly. Generate "delayed mail" warnings after 7 minutes.
16delay_warning_time = 7m
17
18readme_directory = no
19
20# TLS parameters
21smtpd_tls_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem
22smtpd_tls_key_file=/etc/ssl/private/ssl-cert-snakeoil.key
23smtpd_use_tls=yes
24smtpd_tls_session_cache_database = btree:${queue_directory}/smtpd_scache
25smtp_tls_session_cache_database = btree:${queue_directory}/smtp_scache
26
27# See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for
28# information on enabling SSL in the smtp client.
29
30alias_maps = hash:/etc/aliases
31alias_database = hash:/etc/aliases
32relayhost =
33mynetworks = 127.0.0.0/8 !127.84.111.114/32
34mailbox_size_limit = 0
35recipient_delimiter = +
36inet_interfaces = all
37
38# Samizdat: this is necessary for .onion URLs to resolve (until we implement DNSSEC).
39smtp_host_lookup = native
40# postfix versions before 2.11:
41disable_dns_lookups = yes
42# postfix versions 2.11 and later:
43#smtp_dns_support_level = disabled
diff --git a/conf/torrc b/conf/torrc
new file mode 100644
index 0000000..6e387ec
--- /dev/null
+++ b/conf/torrc
@@ -0,0 +1,17 @@
1SocksPort 9050 # what port to open for local application connections
2SocksListenAddress 127.0.0.1 # accept connections only from localhost
3
4HiddenServiceDir /var/lib/tor/samizdat/
5HiddenServicePort 80
6HiddenServicePort 22
7HiddenServicePort 25
8HiddenServicePort 11371
9
10HiddenServiceDir /var/lib/tor/tracker/
11HiddenServicePort 80 127.0.0.1:8070
12HiddenServicePort 2710 127.0.0.1:2710
13
14AutomapHostsOnResolve 1
15VirtualAddrNetwork 10.192.0.0/10
16DNSPort 553
17TransPort 9040