SPECS: snort.spec - removed pld outdated snort config, take one fr...

havner havner at pld-linux.org
Tue Sep 5 12:09:48 CEST 2006


Author: havner                       Date: Tue Sep  5 10:09:48 2006 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- removed pld outdated snort config, take one from rules (vrt 
  registered or vrt unregistered ones)
- added community rulles to config (this might require testing it they
  dont conflict with vrt ones)
- dropped rules subpackage, it was only there because someone package snort
  without any rules at the begining, its no point in keeping it separate
  as snort requires them and snort.conf content is based on rules installed

---- Files affected:
SPECS:
   snort.spec (1.133 -> 1.134) 

---- Diffs:

================================================================
Index: SPECS/snort.spec
diff -u SPECS/snort.spec:1.133 SPECS/snort.spec:1.134
--- SPECS/snort.spec:1.133	Tue Sep  5 11:12:28 2006
+++ SPECS/snort.spec	Tue Sep  5 12:09:42 2006
@@ -38,7 +38,6 @@
 # Source3-md5:	639d98ed81314723f4dee0b3100f7a19
 Source4:	%{name}.init
 Source5:	%{name}.logrotate
-Source6:	%{name}.conf
 Patch0:		%{name}-libnet1.patch
 Patch1:		%{name}-lib64.patch
 # http://www.bleedingsnort.com/staticpages/index.php?page=snort-clamav
@@ -142,18 +141,6 @@
 ŢÁÓŚ, ÎÁÄÓÉĚÁŔŢÉ ĐĎ׌ÄĎÍĚĹÎÎŃ ÄĎ syslog, ĎËŇĹÍĎÇĎ ĆÁĘĚŐ ŢÉ ŃË WinPopup
 ĐĎ׌ÄĎÍĚĹÎÎŃ ŢĹŇĹÚ smbclient.
 
-%package rules
-Summary:	Snort rules
-Summary(pl):	Regułki snorta
-Group:		Networking
-Requires:	%{name} = %{version}-%{release}
-
-%description rules
-Snort rules.
-
-%description rules -l pl
-Regułki snorta.
-
 %prep
 %setup -q %{!?with_registered:-a1} %{?with_registered:-a2} -a3
 %patch0 -p1
@@ -162,6 +149,14 @@
 %endif
 %{?with_clamav:%patch2 -p1}
 
+sed -i "s#var\ RULE_PATH.*#var RULE_PATH /etc/snort/rules#g" rules/snort.conf
+_DIR=$(pwd)
+cd rules
+for I in community-*.rules; do
+	echo "include \$RULE_PATH/$I" >> snort.conf
+done
+cd $_DIR
+
 %build
 %{__aclocal}
 %{__autoconf}
@@ -199,7 +194,8 @@
 install rules/*.rules	$RPM_BUILD_ROOT%{_sysconfdir}/rules
 install %{SOURCE4}	$RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
 install %{SOURCE5}	$RPM_BUILD_ROOT/etc/logrotate.d/%{name}
-install %{SOURCE6}	$RPM_BUILD_ROOT%{_sysconfdir}
+install rules/snort.conf	$RPM_BUILD_ROOT%{_sysconfdir}
+
 
 mv schemas/create_mysql schemas/create_mysql.sql
 mv schemas/create_postgresql schemas/create_postgresql.sql
@@ -246,20 +242,26 @@
 %attr(640,root,snort) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*.config
 %attr(640,root,snort) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/snort.conf
 %attr(750,root,snort) %dir %{_sysconfdir}/rules
+%attr(640,root,snort) %{_sysconfdir}/rules/*
 %attr(754,root,root) /etc/rc.d/init.d/%{name}
 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/*
 %{_mandir}/man?/*
 
-%files rules
-%defattr(644,root,root,755)
-%attr(640,root,snort) %{_sysconfdir}/rules/*
-
 %define	date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
 * %{date} PLD Team <feedback at pld-linux.org>
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.134  2006/09/05 10:09:42  havner
+- removed pld outdated snort config, take one from rules (vrt
+  registered or vrt unregistered ones)
+- added community rulles to config (this might require testing it they
+  dont conflict with vrt ones)
+- dropped rules subpackage, it was only there because someone package snort
+  without any rules at the begining, its no point in keeping it separate
+  as snort requires them and snort.conf content is based on rules installed
+
 Revision 1.133  2006/09/05 09:12:28  havner
 - user 2.4 rules for snapshot rather then current (current are 2.6
   prepared with dynamic plugins)
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SPECS/snort.spec?r1=1.133&r2=1.134&f=u



More information about the pld-cvs-commit mailing list