/[packages]/cauldron/tor/current/SPECS/tor.spec
ViewVC logotype

Contents of /cauldron/tor/current/SPECS/tor.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 196572 - (show annotations) (download)
Sun Jan 15 21:56:08 2012 UTC (9 years, 6 months ago) by dmorgan
File size: 3960 byte(s)
SILENT: Clean spec file
1 %define runuser toruser
2
3 Name: tor
4 Version: 0.2.2.35
5 Release: %mkrel 1
6 Summary: Anonymizing overlay network for TCP (The onion router)
7 URL: http://www.torproject.org/
8 Group: Networking/Other
9 License: BSD-like
10 Requires(pre): rpm-helper
11 Requires(post): rpm-helper
12 Requires(preun): rpm-helper
13 Requires(postun): rpm-helper
14 Requires: openssl >= 0.9.6
15 Requires: tsocks
16 BuildRequires: openssl-devel >= 0.9.6
17 BuildRequires: libevent-devel
18 BuildRequires: zlib-devel
19 BuildRequires: autoconf2.5
20 BuildRequires: transfig, tetex-latex
21 BuildRequires: ghostscript
22 Source0: http://www.torproject.org/dist/%{name}-%{version}.tar.gz
23 Source1: %{name}.logrotate
24 Source2: %{name}.init
25 Source3: %{name}.sysconfig
26
27 %description
28 Tor is a connection-based low-latency anonymous communication system.
29
30 This package provides the "tor" program, which serves as both a client and
31 a relay node. Scripts will automatically create a "%{runuser}" user and
32 group, and set tor up to run as a daemon when the system is rebooted.
33
34 Applications connect to the local Tor proxy using the SOCKS
35 protocol. The local proxy chooses a path through a set of relays, in
36 which each relay knows its predecessor and successor, but no
37 others. Traffic flowing down the circuit is unwrapped by a symmetric
38 key at each relay, which reveals the downstream relay.
39
40 Warnings: Tor does no protocol cleaning. That means there is a danger
41 that application protocols and associated programs can be induced to
42 reveal information about the initiator. Tor depends on Privoxy and
43 similar protocol cleaners to solve this problem. This is alpha code,
44 and is even more likely than released code to have anonymity-spoiling
45 bugs. The present network is very small -- this further reduces the
46 strength of the anonymity provided. Tor is not presently suitable
47 for high-stakes anonymity.
48
49 %prep
50 %setup -q
51
52 %build
53 %configure2_5x
54 %make
55
56 %install
57 %makeinstall
58
59 %define _logdir %{_var}/log
60
61 mkdir -p ${RPM_BUILD_ROOT}%{_initrddir}
62 cat %{SOURCE2} > ${RPM_BUILD_ROOT}%{_initrddir}/%{name}
63 chmod 0755 ${RPM_BUILD_ROOT}%{_initrddir}/%{name}
64
65 install -p -m 644 ${RPM_BUILD_ROOT}%{_sysconfdir}/%{name}/torrc.sample ${RPM_BUILD_ROOT}%{_sysconfdir}/%{name}/torrc
66
67 mkdir -p -m 755 ${RPM_BUILD_ROOT}%{_sysconfdir}/logrotate.d
68 cat %{SOURCE1} > ${RPM_BUILD_ROOT}%{_sysconfdir}/logrotate.d/%{name}
69
70 mkdir -p -m 755 ${RPM_BUILD_ROOT}%{_sysconfdir}/sysconfig/
71 cat %{SOURCE3} > ${RPM_BUILD_ROOT}%{_sysconfdir}/sysconfig/%{name}
72
73 mkdir -p -m 700 ${RPM_BUILD_ROOT}%{_localstatedir}/lib/%{name}
74 mkdir -p -m 755 ${RPM_BUILD_ROOT}%{_var}/run/%{name}
75 mkdir -p -m 755 ${RPM_BUILD_ROOT}%{_logdir}/%{name}
76
77 # Bash completion
78 mkdir -p ${RPM_BUILD_ROOT}%{_sysconfdir}/bash_completion.d
79 echo 'complete -F _command $filenames torify' > ${RPM_BUILD_ROOT}%{_sysconfdir}/bash_completion.d/%{name}
80
81 %pre
82 %_pre_useradd %{runuser} / /bin/false
83
84 %post
85 %_post_service %{name}
86
87 %preun
88 %_preun_service %{name}
89 rm -f %{_localstatedir}/%{name}/cached-directory
90 rm -f %{_localstatedir}/%{name}/bw_accounting
91 rm -f %{_localstatedir}/%{name}/control_auth_cookie
92 rm -f %{_localstatedir}/%{name}/router.desc
93 rm -f %{_localstatedir}/%{name}/fingerprint
94
95 %postun
96 %_postun_userdel %{runuser}
97 %_postun_groupdel %{runuser}
98
99 %files
100 %doc ReleaseNotes INSTALL LICENSE README ChangeLog doc/HACKING doc/TODO
101 %{_mandir}/man*/*
102 %{_bindir}/tor
103 %{_bindir}/torify
104 %{_bindir}/tor-resolve
105 %{_bindir}/tor-gencert
106 %config(noreplace) %attr(0755,%{runuser},%{runuser}) %{_initrddir}/%{name}
107 %config(noreplace) %attr(0644,root,root) %{_sysconfdir}/logrotate.d/%{name}
108 %dir %attr(0755,root,%{runuser}) %{_sysconfdir}/%{name}/
109 %config(noreplace) %attr(0644,root,%{runuser}) %{_sysconfdir}/%{name}/*
110 %config(noreplace) %{_sysconfdir}/sysconfig/%{name}
111 %attr(0700,%{runuser},%{runuser}) %dir %{_localstatedir}/lib/%{name}
112 %attr(0750,%{runuser},%{runuser}) %dir %{_var}/run/%{name}
113 %attr(0750,%{runuser},%{runuser}) %dir %{_logdir}/%{name}
114 %{_sysconfdir}/bash_completion.d/%{name}
115 %{_datadir}/%{name}
116
117

  ViewVC Help
Powered by ViewVC 1.1.28