Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
Tor
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Benjamin J. Thompson
Tor
Commits
a1503f66
Commit
a1503f66
authored
21 years ago
by
Nick Mathewson
Browse files
Options
Downloads
Patches
Plain Diff
Integrate jbash's RPM spec into build process. (Requires "rpmbuild" to
build properly. Works fine on redhat 9. YMMV.) svn:r1199
parent
4f6cf727
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
Makefile.am
+10
-0
10 additions, 0 deletions
Makefile.am
configure.in
+1
-1
1 addition, 1 deletion
configure.in
contrib/Makefile.am
+1
-1
1 addition, 1 deletion
contrib/Makefile.am
contrib/tor.spec.in
+118
-0
118 additions, 0 deletions
contrib/tor.spec.in
with
130 additions
and
2 deletions
Makefile.am
+
10
−
0
View file @
a1503f66
...
...
@@ -9,3 +9,13 @@ EXTRA_DIST = INSTALL README AUTHORS LICENSE ChangeLog
#install-data-local:
# $(INSTALL) -m 755 -d $(LOCALSTATEDIR)/lib/tor
dist-rpm
:
dist
rm
-rf
/tmp/tor-rpm-build
mkdir
/tmp/tor-rpm-build
for
subdir
in
BUILD RPMS SOURCES SPECS SRPMS
;
do
\
mkdir
/tmp/tor-rpm-build/
$$
subdir
;
\
done
cp
tor-
$(
VERSION
)
.tar.gz /tmp/tor-rpm-build/SOURCES
rpmbuild
-ba
--define
'_topdir /tmp/tor-rpm-build'
contrib/tor.spec
mv
/tmp/tor-rpm-build/
*
RPMS/
*
.
This diff is collapsed.
Click to expand it.
configure.in
+
1
−
1
View file @
a1503f66
...
...
@@ -184,5 +184,5 @@ AC_SUBST(LOCALSTATEDIR)
echo "confdir: $CONFDIR"
AC_OUTPUT(Makefile contrib/tor.sh contrib/torify contrib/Makefile src/config/torrc doc/tor.1 src/Makefile doc/Makefile src/config/Makefile src/common/Makefile src/or/Makefile)
AC_OUTPUT(Makefile contrib/tor.sh contrib/torify contrib/Makefile
contrib/tor.spec
src/config/torrc doc/tor.1 src/Makefile doc/Makefile src/config/Makefile src/common/Makefile src/or/Makefile)
This diff is collapsed.
Click to expand it.
contrib/Makefile.am
+
1
−
1
View file @
a1503f66
confdir
=
$(
sysconfdir
)
/tor
EXTRA_DIST
=
tor-tsocks.conf torify.1
EXTRA_DIST
=
tor-tsocks.conf torify.1
tor.spec
conf_DATA
=
tor-tsocks.conf
...
...
This diff is collapsed.
Click to expand it.
contrib/tor.spec
→
contrib/tor.spec
.in
+
118
−
0
View file @
a1503f66
%define rellevel
1
%define rellevel
2
%define relbase std.%{rellevel}
%define rhrel %([ -f /etc/redhat-release ] && (sed -e 's/^Red Hat Linux release //' -e 's/ .*$//' -e 's/\\./_/g' -e 's/^.*$/.rh&/' < /etc/redhat-release))
%define blddate %(date -u +"%Y%m%d%H%M")
...
...
@@ -6,16 +6,16 @@
%define initdir /etc/rc.d/init.d
Summary: tor:
anonymizing overlay network for TCP
Summary: tor:
The Onion Router; patent-free Onion Routing
Name: tor
Version:
0.0.2pre20
Version:
@VERSION@
Vendor: R. Dingledine <arma@seul.org>
Release: %{release}
License: BSD-like
Group: Applications/Internet
URL: http://freehaven.net/tor
Source0: http://freehaven.net/tor/dist/tor-
0.0.2pre19
.tar.gz
Source0: http://freehaven.net/tor/dist/tor-
%{version}
.tar.gz
Requires(pre): shadow-utils, /usr/bin/id, /bin/date, /bin/sh
Requires(pre): %{_sbindir}/useradd, %{_sbindir}/groupadd
...
...
@@ -23,34 +23,15 @@ Requires(pre): %{_sbindir}/useradd, %{_sbindir}/groupadd
BuildRoot: %{_tmppath}/%{name}-%{version}-%{relbase}-root
%description
Tor is a connection-based low-latency anonymous communication system which
addresses many flaws in the original onion routing design.
In brief, 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.
Basically Tor provides a distributed network of servers ("onion
routers"). Users bounce their tcp streams (web traffic, ftp, ssh, etc)
around the routers, and recipients, observers, and even the routers
themselves have difficulty tracking the source of the stream.
Note that Tor does no protocol cleaning. That means there is a danger that
application protocols and associated programs can be induced to reveal
information about the initiator. Tor depends on Privoxy and similar protocol
cleaners to solve this problem.
Client applications can use the Tor network by connecting to the local
onion proxy. If the application itself does not come with socks support
you can use a socks client such as tsocks. Some web browsers like mozilla
and web proxies like privoxy come with socks support, so you don't need an
extra socks client if you want to use Tor with them.
Remember that this is alpha code, and the network is very small -- Tor will
not provide anonymity currently.
Tor is a system that conceals the sources of TCP connections
by relaying those connections through multiple independently administered
forwarding nodes; it is a "cascaded mix" system. Among older systems,
Tor is most similar to Onion Routing. The basic concept of Tor is also
similar to that of the Zero Knowledge Freedom system or the Java Anonymous
Proxy. The "onions" used in Tor are similar in concept to the reply blocks
used with type I "cypherpunks" anonymous remailers. Feeding phrases
from this paragraph into search engines should give you more background
information than you really want.
This package provides the "tor" program, which serves as both a client
and a relay node. Scripts will automatically create a "tor" user and
...
...
@@ -60,26 +41,12 @@ installation time.
%prep
%setup -q
# Patch the startup script to use the right user and group IDs, store
# the PID in a subdirectory of /var/run (so tor doesn't have to start
# as root) and add in a control line for chkconfig. This (BSD? Debian?)
# script will work, but doesn't use all the weird Red Hat macros to make
# the boot sequence look pretty.
ed -s tor.sh.in << '/EOF/' > /dev/null
# Change the PID file location
,s/^TORPID=\(.*\)\/run\/tor.pid/TORPID=\1\/run\/tor\/tor.pid/
#
# Set user to "tor" before starting tor
,s/^\([ ]*\)\(\$TORBIN.*\)$/\1\/bin\/su -s \/bin\/sh -c "\2" tor/
#
# Add user and group to command line. Suspenders and belt.
,s/^TORARGS="\(.*\)"/TORARGS="\1 --user tor --group tor"/
#
# Add control lines for chkconfig
1a
# chkconfig: 2345 90 10
# description: Onion router
.
# Patch the startup script to use the right user and group IDs. Force
# the use of /bin/sh as the shell for the "tor" account.
ed -s contrib/tor.sh.in << '/EOF/' > /dev/null
,s/^TORUSER=$/TORUSER=tor/
,s/^TORGROUP=$/TORGROUP=tor/
,s:/bin/su:/bin/su -s /bin/sh:
#
# Save and exit ed
w
...
...
@@ -95,7 +62,7 @@ q
# Install init script.
%__mkdir_p ${RPM_BUILD_ROOT}%{initdir}
%__install -m 755 tor.sh ${RPM_BUILD_ROOT}%{initdir}/tor
%__install -m 755
contrib/
tor.sh ${RPM_BUILD_ROOT}%{initdir}/tor
# Directories that don't have any preinstalled files
%__mkdir_p -m 700 ${RPM_BUILD_ROOT}/var/lib/tor
...
...
@@ -116,18 +83,18 @@ if [ ! -n "`/usr/bin/id -u tor 2>/dev/null`" ]; then
# One would also like to default the UID, but doing that properly would
# also require thought.
if [ -x /sbin/nologin ]; then
%{_sbindir}/useradd -g tor -d / -s /sbin/nologin tor 2> /dev/null
%{_sbindir}/useradd
-r
-g tor -d / -s /sbin/nologin tor 2> /dev/null
else
%{_sbindir}/useradd -g tor -d / -s /bin/false tor 2> /dev/null
%{_sbindir}/useradd
-r
-g tor -d / -s /bin/false tor 2> /dev/null
fi
fi
%post
/sbin/chkconfig --add tor
/sbin/service tor start
/sbin/chkconfig tor &&
/sbin/service tor start
%preun
/sbin/service tor stop
/sbin/chkconfig tor &&
/sbin/service tor stop
/sbin/chkconfig --del tor
%files
...
...
@@ -135,10 +102,12 @@ fi
%doc AUTHORS INSTALL LICENSE README
%{_mandir}/man*/*
%{_bindir}/tor
%{_bindir}/torify
%{initdir}/tor
%dir %{_sysconfdir}/tor/
%config(noreplace) %{_sysconfdir}/tor/torrc
%config(noreplace) %{_sysconfdir}/tor/dirservers
%config(noreplace) %{_sysconfdir}/tor/tor-tsocks.conf
%attr(-,tor,tor) %dir /var/lib/tor
%attr(-,tor,tor) %dir /var/run/tor
%attr(-,tor,tor) %dir /var/log/tor
...
...
@@ -146,3 +115,4 @@ fi
%changelog
* Sat Jan 17 2004 John Bashinski <jbash@velvet.com>
- Basic spec file; tested with Red Hat 9.
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment