tordam

A library for peer discovery inside the Tor network
git clone https://git.parazyd.org/tordam
Log | Files | Refs | README | LICENSE

commit 24156de26fb67ba8a61df74c94c7796ff98ebad2
parent b98456ed265504cce1b763a18f15c9282d6c53e6
Author: parazyd <parazyd@dyne.org>
Date:   Fri,  8 Dec 2017 13:23:57 +0100

Add example configurations; improve makefiles

Diffstat:
AMakefile | 14++++++++++++++
MREADME.md | 7++++---
Acontrib/redis.conf | 20++++++++++++++++++++
Acontrib/torrc | 16++++++++++++++++
Mpython/Makefile | 9+++++++++
5 files changed, 63 insertions(+), 3 deletions(-)

diff --git a/Makefile b/Makefile @@ -0,0 +1,14 @@ +# See LICENSE file for copyright and license details. + +PREFIX ?= /usr/local + +all: + @echo 'Run "make install" to install into $(DESTDIR)$(PREFIX)' + +install: + @make -C python install + +uninstall: + @make -C python uninstall + +.PHONY: all install uninstall diff --git a/README.md b/README.md @@ -29,9 +29,8 @@ The Go dependencies should be pulled in with `go get`. You can install `stem` possibly with your package manager, or download it from the website itself. -To install the Python scripts, go to the directory where go has -downloaded tor-dam, enter the `python` directory and run `make install` -as root. +To install everything else, go to the directory where go has downloaded +tor-dam and run `make install` as root. External software dependendies include `redis` and `tor`. You can retrieve them using your package manager. @@ -41,3 +40,5 @@ CookieAuthentication or a password, for stem to authenticate and be able to create hidden services and retrieve hidden service descriptors. Redis is our storage backend where information about nodes is held. + +Working configurations are provided in the `contrib` directory. diff --git a/contrib/redis.conf b/contrib/redis.conf @@ -0,0 +1,20 @@ +# +# Redis configuration for tor-dam +# + +daemonize yes + +bind 127.0.0.1 +port 6379 + +databases 1 +dbfilename decode-dir.rdb + +save 900 1 +save 300 10 +save 60 10000 + +rdbcompression yes +rdbchecksum yes + +stop-writes-on-bgsave-error yes diff --git a/contrib/torrc b/contrib/torrc @@ -0,0 +1,16 @@ +# +# Minimal torrc so tor will work out of the box +# + +User tor +PIDFile /var/run/tor/tor.pid +Log notice syslog +DataDirectory /var/lib/tor/data + +ControlPort 9051 +CookieAuthentication 1 +HashedControlPassword 16:6091EDA9F3F5F8EB60C8423561CB8C46B3CCF033E88FEACA1FC8BDBB9A + +SocksPort 9050 + +ClientRejectInternalAddresses 1 diff --git a/python/Makefile b/python/Makefile @@ -13,3 +13,12 @@ install: @echo 'Installing scripts to $(DESTDIR)$(PREFIX)/bin' mkdir -p $(DESTDIR)$(PREFIX)/bin cp -f $(BIN) $(DESTDIR)$(PREFIX)/bin + cd $(DESTDIR)$(PREFIX)/bin + chmod 755 $(BIN) + +uninstall: + @echo 'Uninstalling scripts from $(DESTDIR)$(PREFIX)/bin' + cd $(DESTDIR)$(PREFIX)/bin + rm -f $(BIN) + +.PHONY: all install uninstall