/[smeserver]/rpms/rkhunter/sme7/rkhunter.spec
ViewVC logotype

Annotation of /rpms/rkhunter/sme7/rkhunter.spec

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.11 - (hide annotations) (download)
Sun Mar 2 21:48:21 2008 UTC (16 years, 9 months ago) by slords
Branch: MAIN
CVS Tags: rkhunter-1_3_2-2_el4_sme
Changes since 1.10: +5 -1 lines
Updates

1 slords 1.2 # No debuginfo:
2     %define debug_package %{nil}
3    
4     # If you want to debug, uncomment the next line and remove
5     # the duplicate percent sign (due to macro expansion)
6     #%%dump
7    
8     %define name rkhunter
9 slords 1.9 %define ver 1.3.2
10 slords 1.11 %define rel 2
11 slords 1.2 %define epoch 0
12    
13     # Don't change this define or also:
14     # 1. installer.sh --layout custom /temporary/dir/usr --striproot /temporary/dir --install
15     # 2. rewrite the files section below.
16     %define _prefix /usr
17    
18 slords 1.1 # We can't let RPM do the dependencies automatic because it'll then pick up
19     # a correct but undesirable perl dependency, which rkhunter does not require
20     # in order to function properly.
21     AutoReqProv: no
22    
23 slords 1.2 Name: %{name}
24     Summary: %{name} scans for rootkits, backdoors and local exploits
25     Version: %{ver}
26     Release: %{rel}%{dist}
27     Epoch: %{epoch}
28     License: GPL
29     Group: Applications/System
30     Source0: %{name}-%{version}.tar.gz
31     Patch0: rkhunter-installer.patch
32 bytegw 1.5 Patch1: rkhunter-nolib.patch
33 slords 1.2 BuildArch: noarch
34     Requires: filesystem, bash, grep, findutils, net-tools, coreutils, e2fsprogs, modutils, procps, binutils, wget, perl
35     Provides: %{name}
36     URL: http://rkhunter.sourceforge.net/
37     BuildRoot: %{_tmppath}/%{name}-%{version}
38 slords 1.1
39     %description
40 slords 1.2 Rootkit Hunter is a scanning tool to ensure you are about 99.9%%
41     clean of nasty tools. It scans for rootkits, backdoors and local
42 slords 1.1 exploits by running tests like:
43 slords 1.2 - File hash check
44 slords 1.1 - Look for default files used by rootkits
45     - Wrong file permissions for binaries
46     - Look for suspected strings in LKM and KLD modules
47     - Look for hidden files
48     - Optional scan within plaintext and binary files
49     - Software version checks
50     - Application tests
51    
52     Rootkit Hunter is released as a GPL licensed project and free for everyone to use.
53    
54    
55     %prep
56 slords 1.2 %setup -q
57     %patch0 -p1
58 bytegw 1.5 %patch1 -p1
59 slords 1.1
60     %build
61    
62     %install
63 slords 1.9 MANPATH=""
64     export MANPATH
65    
66 slords 1.2 sh ./installer.sh --layout RPM --install
67 slords 1.1
68 slords 1.3 sed -i 's_#ALLOWPROCLISTEN=/sbin/dhclient_ALLOWPROCLISTEN=/sbin/dhclient_' ${RPM_BUILD_ROOT}%{_sysconfdir}/%{name}.conf
69 bytegw 1.7 sed -i 's_#ALLOWPROCLISTEN=/usr/sbin/pppoe_ALLOWPROCLISTEN=/sbin/pppoe_' ${RPM_BUILD_ROOT}%{_sysconfdir}/%{name}.conf
70 slords 1.3 sed -i 's_#ALLOWHIDDENFILE=/usr/share/man/man1/..1.gz_ALLOWHIDDENFILE=/usr/share/man/man1/..1.gz_' ${RPM_BUILD_ROOT}%{_sysconfdir}/%{name}.conf
71 bytegw 1.4 sed -i '/#ALLOWPROCLISTEN=\/usr\/bin\/dhcpcd/iALLOWPROCLISTEN=\/usr\/sbin\/dhcpd' ${RPM_BUILD_ROOT}%{_sysconfdir}/%{name}.conf
72 slords 1.3 sed -i '/#ALLOWPROCDELFILE=\/usr\/sbin\/mysqld/aALLOWPROCDELFILE=\/usr\/sbin\/httpd' ${RPM_BUILD_ROOT}%{_sysconfdir}/%{name}.conf
73 slords 1.8 sed -i '/ALLOWPROCDELFILE=\/usr\/sbin\/httpd/aALLOWPROCDELFILE=\/usr\/sbin\/asterisk' ${RPM_BUILD_ROOT}%{_sysconfdir}/%{name}.conf
74 slords 1.11 sed -i '/ALLOWPROCDELFILE=\/usr\/sbin\/httpd/aALLOWPROCDELFILE=\/usr\/bin\/freshclam' ${RPM_BUILD_ROOT}%{_sysconfdir}/%{name}.conf
75 slords 1.1
76 slords 1.2 # Make a cron.daily file to mail us the reports
77 slords 1.1 %{__mkdir} -p "${RPM_BUILD_ROOT}/%{_sysconfdir}/cron.daily"
78     %{__cat} > "${RPM_BUILD_ROOT}/%{_sysconfdir}/cron.daily/01-rkhunter" <<EOF
79     #!/bin/sh
80 slords 1.6 %{_bindir}/rkhunter --cronjob --update --disable apps,suspscan,system_commands --rwo
81 slords 1.2 exit 0
82 slords 1.1 EOF
83     %{__chmod} a+rwx,g-w,o-rwx ${RPM_BUILD_ROOT}%{_sysconfdir}/cron.daily/01-rkhunter
84    
85    
86 slords 1.2 %post
87     # Only do this on an initial install
88     if [ $1 -eq 1 ]; then
89 bytegw 1.5 %{__cp} -p /etc/passwd /var/rkhunter/tmp >/dev/null 2>&1 || :
90     %{__cp} -p /etc/group /var/rkhunter/tmp >/dev/null 2>&1 || :
91 slords 1.2 fi
92 slords 1.1
93    
94 slords 1.2 %preun
95     # Only do this when removing the RPM
96     if [ $1 -eq 0 ]; then
97     %{__rm} -f /var/log/rkhunter.log /var/log/rkhunter.log.old >/dev/null 2>&1
98 bytegw 1.5 %{__rm} -rf /var/rkhunter/* >/dev/null 2>&1
99 slords 1.2 fi
100 slords 1.1
101    
102 slords 1.2 %clean
103     if [ "$RPM_BUILD_ROOT" = "/" ]; then
104     echo Invalid Build root \'"$RPM_BUILD_ROOT"\'
105     exit 1
106     else
107     rm -rf $RPM_BUILD_ROOT
108     fi
109 slords 1.1
110    
111 slords 1.2 %define docdir %{_prefix}/share/doc/%{name}-%{version}
112     %files
113     %defattr(-,root,root)
114     %attr(640,root,root) %config(noreplace) %{_sysconfdir}/%{name}.conf
115     %attr(750,root,root) %{_prefix}/bin/%{name}
116     %attr(750,root,root) %dir %{_libdir}/%{name}
117     %attr(750,root,root) %dir %{_libdir}/%{name}/scripts
118     %attr(750,root,root) %{_libdir}/%{name}/scripts/*.pl
119     %attr(750,root,root) %{_libdir}/%{name}/scripts/*.sh
120     %attr(644,root,root) %doc %{_prefix}/share/man/man8/%{name}.8.gz
121     %attr(755,root,root) %dir %{docdir}
122     %attr(644,root,root) %doc %{docdir}/*
123 bytegw 1.5 %attr(750,root,root) %dir %{_var}/%{name}
124     %attr(750,root,root) %dir %{_var}/%{name}/db
125     %attr(640,root,root) %{_var}/%{name}/db/*.dat
126     %attr(750,root,root) %dir %{_var}/%{name}/db/i18n
127     %attr(640,root,root) %{_var}/%{name}/db/i18n/*
128     %attr(750,root,root) %dir %{_var}/%{name}/tmp
129 slords 1.2 %{_sysconfdir}/cron.daily/01-rkhunter
130 slords 1.1
131    
132 slords 1.2 %changelog
133 slords 1.11 * Sun Mar 2 2008 Shad L. Lords <slords@mail.com> 1.3.2-2
134     - Allow freshclam to use deleted files. [SME: 3876]
135    
136 slords 1.9 * Fri Feb 29 2008 Shad L. Lords <slords@mail.com> 1.3.2-1
137 bytegw 1.10 - Update to rkhunter v1.3.2 [SME: 4000]
138 slords 1.9
139 slords 1.8 * Wed Jan 30 2008 Shad L. Lords <slords@mail.com> 1.3.0-6
140     - Fix asterisk to allow deleted files. [SME: 3795]
141    
142 bytegw 1.7 * Tue Jan 29 2008 Shad L. Lords <slords@mail.com> 1.3.0-5
143     - Correct pppoe binary location.
144     - Add asterisk binary to allow deleted files. [SME: 3795]
145    
146 slords 1.6 * Mon Jan 7 2008 Shad L. Lords <slords@mail.com> 1.3.0-4
147     - Disable scan for suspicious files until fixed [SME: 3713]
148    
149 bytegw 1.5 * Mon Dec 17 2007 Shad L. Lords <slords@mail.com> 1.3.0-3
150     - Change /var/lib to /var to be consistent with previous versions
151    
152 bytegw 1.4 * Mon Dec 17 2007 Shad L. Lords <slords@mail.com> 1.3.0-2
153     - Add a few more services for sme tests
154    
155 slords 1.2 * Mon Dec 17 2007 Shad L. Lords <slords@mail.com> 1.3.0-1
156     - Fix installer to not install in local
157 slords 1.3 - Set parameters for sme specific tests
158 slords 1.1
159 slords 1.2 * Sun Feb 11 2007 unSpawn - pre-1.3.0
160     - Sync spec with fixes, installer and CVS
161 slords 1.1
162 slords 1.2 * Sun Nov 12 2006 unSpawn - 1.2.9
163     - Re-spec, new installer
164 slords 1.1
165 slords 1.2 * Fri Sep 29 2006 unSpawn - 1.2.9
166     - Updated for release 1.2.9
167 slords 1.1
168     * Tue Aug 10 2004 Michael Boelen - 1.1.5
169     - Added update script
170     - Extended description
171    
172     * Sun Aug 08 2004 Greg Houlette - 1.1.5
173     - Changed the install procedure eliminating the specification of
174     destination filenames (only needed if you are renaming during install)
175     - Changed the permissions for documentation files (root only overkill)
176     - Added the installation of the rkhunter Man Page
177     - Added the installation of the programs_{bad, good}.dat database files
178     - Added the installation of the LICENSE documentation file
179     - Added the chmod for root only to the /var/rkhunter/db directory
180    
181     * Sun May 23 2004 Craig Orsinger (cjo) <cjorsinger@earthlink.net>
182     - version 1.1.0-1.cjo
183     - changed installation in accordance with new rootkit installation
184     procedure
185     - changed installation root to conform to LSB. Use standard macros.
186     - added recursive remove of old build root as prep for install phase
187    
188     * Wed Apr 28 2004 Doncho N. Gunchev - 1.0.9-0.mr700
189     - dropped Requires: perl - rkhunter works without it
190     - dropped the bash alignpatch (check the source or contact me)
191     - various file mode fixes (.../tmp/, *.db)
192     - optimized the %%files section - any new files in the
193     current dirs will be fine - just %%{__install} them.
194    
195     * Mon Apr 26 2004 Michael Boelen - 1.0.8-0
196     - Fixed missing md5blacklist.dat
197    
198     * Mon Apr 19 2004 Doncho N. Gunchev - 1.0.6-1.mr700
199     - added missing /usr/local/rkhunter/db/md5blacklist.dat
200     - patched to align results in --cronjob, I think rpm based
201     distros have symlink /bin/sh -> /bin/bash
202     - added --with/--without alignpatch for conditional builds
203     (in case previous patch breaks something)
204    
205     * Sat Apr 03 2004 Michael Boelen / Joe Klemmer - 1.0.6-0
206     - Update to 1.0.6
207    
208     * Mon Mar 29 2004 Doncho N. Gunchev - 1.0.0-0
209     - initial .spec file
210    
211 slords 1.2

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed