pkgsrc-WIP-changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Initial import of tor 0.3.2.4-alpha.
Module Name: pkgsrc-wip
Committed By: Alexander Nasonov <alnsn%yandex.ru@localhost>
Pushed By: alnsn
Date: Sun Nov 12 17:09:18 2017 +0000
Changeset: 8441fabf4104fecf65cfe857f9a05843998e82cf
Added Files:
tor-dev/DESCR
tor-dev/MESSAGE
tor-dev/Makefile
tor-dev/PLIST
tor-dev/distinfo
tor-dev/files/tordev.in
tor-dev/options.mk
tor-dev/patches/patch-Makefile.in
tor-dev/patches/patch-src_or_config.c
Log Message:
Initial import of tor 0.3.2.4-alpha.
It includes support for the next-generation ("v3") onion service protocol,
adds a new circuit scheduler for more responsive forwarding decisions
from relays, and adds HTTPTunnelPort option to open a port that accepts
HTTP CONNECT requests.
All changes introduced in 0.3.2.x are listed here:
https://blog.torproject.org/tor-0321-alpha-released-support-next-gen-onion-services-and-kist-scheduler
https://blog.torproject.org/tor-0322-alpha-released
https://blog.torproject.org/tor-0323-alpha-released-small-bugfixes
https://blog.torproject.org/tor-0324-alpha-released-several-stability-fixes
To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=8441fabf4104fecf65cfe857f9a05843998e82cf
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
diffstat:
tor-dev/DESCR | 13 ++++++
tor-dev/MESSAGE | 9 ++++
tor-dev/Makefile | 77 +++++++++++++++++++++++++++++++++++
tor-dev/PLIST | 17 ++++++++
tor-dev/distinfo | 8 ++++
tor-dev/files/tordev.in | 46 +++++++++++++++++++++
tor-dev/options.mk | 22 ++++++++++
tor-dev/patches/patch-Makefile.in | 17 ++++++++
tor-dev/patches/patch-src_or_config.c | 27 ++++++++++++
9 files changed, 236 insertions(+)
diffs:
diff --git a/tor-dev/DESCR b/tor-dev/DESCR
new file mode 100644
index 0000000000..85ec1a5ec9
--- /dev/null
+++ b/tor-dev/DESCR
@@ -0,0 +1,13 @@
+The simple version: Tor provides a distributed network of servers ("onion
+routers"). Users bounce their TCP streams (web traffic, FTP, SSH, etc.) around
+the routers. This makes it hard for recipients, observers, and even the onion
+routers themselves to track the source of the stream.
+
+The complex version: Onion Routing is a connection-oriented anonymizing
+communication service. Users choose a source-routed path through a set of
+nodes, and negotiate a "virtual circuit" through the network, in which each
+node knows its predecessor and successor, but no others. Traffic flowing down
+the circuit is unwrapped by a symmetric key at each node, which reveals the
+downstream node.
+
+This version is not a stable Tor release. Expect more bugs than usual.
diff --git a/tor-dev/MESSAGE b/tor-dev/MESSAGE
new file mode 100644
index 0000000000..4ea5dd4845
--- /dev/null
+++ b/tor-dev/MESSAGE
@@ -0,0 +1,9 @@
+===========================================================================
+$NetBSD$
+
+Please note that the only way the Tor Project recommends browsing the
+web through Tor is the Tor Browser, which is packaged as
+security/tor-browser. See security/tor-browser/MESSAGE too.
+
+This version is not a stable Tor release. Expect more bugs than usual.
+===========================================================================
diff --git a/tor-dev/Makefile b/tor-dev/Makefile
new file mode 100644
index 0000000000..bfb6a9b7d6
--- /dev/null
+++ b/tor-dev/Makefile
@@ -0,0 +1,77 @@
+# $NetBSD$
+
+DISTNAME= tor-0.3.2.4-alpha
+PKGNAME= ${DISTNAME:S/tor/tordev/:S/-alpha//}
+CATEGORIES= net security
+MASTER_SITES= http://www.torproject.org/dist/
+
+MAINTAINER= alnsn%NetBSD.org@localhost
+HOMEPAGE= http://www.torproject.org/
+COMMENT= Anonymizing overlay network for TCP
+LICENSE= modified-bsd
+
+USE_LANGUAGES= c99
+USE_PKGLOCALEDIR= yes
+GNU_CONFIGURE= yes
+
+CONFIGURE_ENV+= CPP=${CPP:Q}
+CONFIGURE_ENV+= CONFDIR=${PKG_SYSCONFDIR}
+CONFIGURE_ARGS+= --program-suffix=-dev
+CONFIGURE_ARGS+= --sysconfdir=${PKG_SYSCONFBASEDIR}
+CONFIGURE_ARGS+= --docdir=${PREFIX}/share/doc/tordev
+
+# one test failure in 0.3.0.10
+# https://trac.torproject.org/projects/tor/ticket/23250
+TEST_TARGET= check
+
+TOR_USER?= tordev
+TOR_GROUP?= tor
+PKG_GECOS.${TOR_USER}= Torifier
+PKG_HOME.${TOR_USER}= ${VARBASE}/chroot/tordev
+BUILD_DEFS+= VARBASE
+PKG_SYSCONFSUBDIR= tordev
+
+PKG_GROUPS_VARS+= TOR_GROUP
+PKG_USERS_VARS= TOR_USER
+
+RCD_SCRIPTS= tordev
+RCD_SCRIPT_SRC.tordev= ${FILESDIR}/tordev.in
+PKG_GROUPS= ${TOR_GROUP}
+PKG_USERS= ${TOR_USER}:${TOR_GROUP}
+USER_GROUP= ${TOR_USER} ${TOR_GROUP}
+
+OWN_DIRS_PERMS+= ${PKG_HOME.${TOR_USER}} ${USER_GROUP} 0700
+
+CONFIGURE_ARGS+= --localstatedir=${VARBASE}
+
+CONF_FILES+= ${PREFIX}/share/examples/tordev/torrc.sample \
+ ${PKG_SYSCONFDIR}/torrc
+
+PRINT_PLIST_AWK+= /^man\/man/ { $$0 = "$${PLIST.doc}" $$0 }
+PRINT_PLIST_AWK+= /^share\/doc/ { $$0 = "$${PLIST.doc}" $$0 }
+
+FILES_SUBST+= PKG_HOME=${PKG_HOME.${TOR_USER}}
+FILES_SUBST+= TOR_USER=${TOR_USER} TOR_GROUP=${TOR_GROUP}
+
+INSTALL_MAKE_FLAGS+= sysconfdir=${PREFIX}/share/examples
+
+CHECK_PORTABILITY_SKIP+=contrib/*
+
+.include "../../mk/bsd.prefs.mk"
+
+.if !empty(PKGSRC_COMPILER:Mmipspro)
+CFLAGS+= -c99
+.endif
+
+BUILDLINK_API_DEPENDS.libevent+= libevent>=2.0
+.include "../../devel/libevent/buildlink3.mk"
+.include "../../devel/zlib/buildlink3.mk"
+BUILDLINK_API_DEPENDS.openssl+= openssl>=1.0
+.include "../../security/openssl/buildlink3.mk"
+.include "../../mk/pthread.buildlink3.mk"
+
+## We include this after other b3.mk files since we use PTHREAD_TYPE.
+##
+.include "options.mk"
+
+.include "../../mk/bsd.pkg.mk"
diff --git a/tor-dev/PLIST b/tor-dev/PLIST
new file mode 100644
index 0000000000..d55baf3643
--- /dev/null
+++ b/tor-dev/PLIST
@@ -0,0 +1,17 @@
+@comment $NetBSD$
+bin/tor-dev
+bin/tor-gencert-dev
+bin/tor-resolve-dev
+bin/torify-dev
+${PLIST.doc}man/man1/tor-gencert-dev.1
+${PLIST.doc}man/man1/tor-resolve-dev.1
+${PLIST.doc}man/man1/tor-dev.1
+${PLIST.doc}man/man1/torify-dev.1
+${PLIST.doc}share/doc/tordev/tor-gencert.html
+${PLIST.doc}share/doc/tordev/tor-resolve.html
+${PLIST.doc}share/doc/tordev/tor.html
+${PLIST.doc}share/doc/tordev/torify.html
+share/examples/rc.d/tordev
+share/examples/tordev/torrc.sample
+share/tordev/geoip
+share/tordev/geoip6
diff --git a/tor-dev/distinfo b/tor-dev/distinfo
new file mode 100644
index 0000000000..d518318801
--- /dev/null
+++ b/tor-dev/distinfo
@@ -0,0 +1,8 @@
+$NetBSD$
+
+SHA1 (tor-0.3.2.4-alpha.tar.gz) = 2e0d5d5dd6198b20a232b695d4179531dc7f6a55
+RMD160 (tor-0.3.2.4-alpha.tar.gz) = 46884080b9a4244ffa3a349c9235f273ab2d2a8f
+SHA512 (tor-0.3.2.4-alpha.tar.gz) = 8ed5cf13cdaabd92034a1bb4580f112b09a2369a5d8dc05b788b1a4c8c4a9b683e4329a7fe2a03b5e7491c2fbbde6a3bd359e821e04f36cf553adef192c01df2
+Size (tor-0.3.2.4-alpha.tar.gz) = 6282717 bytes
+SHA1 (patch-Makefile.in) = f3e51f568aa7c4338d352689d1ab2f0bb10aa016
+SHA1 (patch-src_or_config.c) = 6cc372ca1809ff8cb7f5cc181f8e7a735d1148cb
diff --git a/tor-dev/files/tordev.in b/tor-dev/files/tordev.in
new file mode 100644
index 0000000000..c13774b7ad
--- /dev/null
+++ b/tor-dev/files/tordev.in
@@ -0,0 +1,46 @@
+#!@RCD_SCRIPTS_SHELL@
+#
+# $NetBSD$
+#
+# PROVIDE: tordev
+# REQUIRE: DAEMON NETWORKING
+# KEYWORD: shutdown
+#
+# You will need to set some variables in /etc/rc.conf to start tordev:
+#
+# tordev=YES
+
+if [ -f /etc/rc.subr ]
+then
+ . /etc/rc.subr
+fi
+
+name="tordev"
+rcvar=$name
+command="@PREFIX@/bin/tor-dev"
+required_files="@PKG_SYSCONFDIR@/torrc"
+start_cmd="tor_start"
+stop_cmd="tor_stop"
+pidfile="@PKG_HOME@/${name}.pid"
+restart_cmd="tor_stop ; tor_start"
+extra_commands="reload"
+
+tor_start ()
+{
+ ${command} --User @TOR_USER@ --RunAsDaemon 1 \
+ --DataDirectory @PKG_HOME@ --PIDFile ${pidfile}
+}
+
+tor_stop()
+{
+ kill `cat ${pidfile}` 2>/dev/null
+}
+
+if [ -f /etc/rc.subr -a -f /etc/rc.conf -a -d /etc/rc.d -a -f /etc/rc.d/DAEMON ]
+then
+ load_rc_config $name
+ run_rc_command "$1"
+else
+ eval ${start_cmd}
+fi
+
diff --git a/tor-dev/options.mk b/tor-dev/options.mk
new file mode 100644
index 0000000000..48e9a53ffd
--- /dev/null
+++ b/tor-dev/options.mk
@@ -0,0 +1,22 @@
+# $NetBSD$
+
+PKG_OPTIONS_VAR= PKG_OPTIONS.tordev
+PKG_SUPPORTED_OPTIONS= doc
+PKG_SUGGESTED_OPTIONS+= doc
+
+.include "../../mk/bsd.options.mk"
+
+PLIST_VARS+= doc
+
+###
+### This enables the build of manual pages. It requires asciidoc
+### at build time, which comes with a tail of dependencies and
+### may not be wanted under certain circumstances.
+###
+.if !empty(PKG_OPTIONS:Mdoc)
+BUILD_DEPENDS+= asciidoc>=8.3.3:../../textproc/asciidoc
+CONFIGURE_ARGS+= --enable-asciidoc
+PLIST.doc= yes
+.else
+CONFIGURE_ARGS+= --disable-asciidoc
+.endif
diff --git a/tor-dev/patches/patch-Makefile.in b/tor-dev/patches/patch-Makefile.in
new file mode 100644
index 0000000000..b6063f22e6
--- /dev/null
+++ b/tor-dev/patches/patch-Makefile.in
@@ -0,0 +1,17 @@
+$NetBSD$
+
+tor -> tordev.
+
+--- Makefile.in.orig 2017-11-09 22:35:20.595595671 +0000
++++ Makefile.in
+@@ -2954,8 +2954,8 @@ src_tools_tor_gencert_LDADD = src/common
+ @COVERAGE_ENABLED_TRUE@ @TOR_LIB_MATH@ @TOR_ZLIB_LIBS@ @TOR_OPENSSL_LIBS@ \
+ @COVERAGE_ENABLED_TRUE@ @TOR_LIB_WS32@ @TOR_LIB_GDI@ @CURVE25519_LIBS@
+
+-confdir = $(sysconfdir)/tor
+-tordatadir = $(datadir)/tor
++confdir = $(sysconfdir)/tordev
++tordatadir = $(datadir)/tordev
+ conf_DATA = src/config/torrc.sample
+ tordata_DATA = src/config/geoip src/config/geoip6
+
diff --git a/tor-dev/patches/patch-src_or_config.c b/tor-dev/patches/patch-src_or_config.c
new file mode 100644
index 0000000000..1ff31fd4f6
--- /dev/null
+++ b/tor-dev/patches/patch-src_or_config.c
@@ -0,0 +1,27 @@
+$NetBSD$
+
+tor -> tordev.
+
+--- src/or/config.c.orig 2017-11-05 19:09:21.000000000 +0000
++++ src/or/config.c
+@@ -349,9 +349,9 @@ static config_var_t option_vars_[] = {
+ V(GeoIPv6File, FILENAME, "<default>"),
+ #else
+ V(GeoIPFile, FILENAME,
+- SHARE_DATADIR PATH_SEPARATOR "tor" PATH_SEPARATOR "geoip"),
++ SHARE_DATADIR PATH_SEPARATOR "tordev" PATH_SEPARATOR "geoip"),
+ V(GeoIPv6File, FILENAME,
+- SHARE_DATADIR PATH_SEPARATOR "tor" PATH_SEPARATOR "geoip6"),
++ SHARE_DATADIR PATH_SEPARATOR "tordev" PATH_SEPARATOR "geoip6"),
+ #endif /* defined(_WIN32) */
+ OBSOLETE("Group"),
+ V(GuardLifetime, INTERVAL, "0 minutes"),
+@@ -7646,7 +7646,7 @@ normalize_data_directory(or_options_t *o
+ "\"%s\", which is probably not what you want. Using "
+ "\"%s"PATH_SEPARATOR"tor\" instead", fn, LOCALSTATEDIR);
+ tor_free(fn);
+- fn = tor_strdup(LOCALSTATEDIR PATH_SEPARATOR "tor");
++ fn = tor_strdup(LOCALSTATEDIR PATH_SEPARATOR "tordev");
+ }
+ tor_free(options->DataDirectory);
+ options->DataDirectory = fn;
Home |
Main Index |
Thread Index |
Old Index