2 %bcond_without pgsql # build without PostgreSQL support
3 %bcond_without mysql # build without MySQL support
4 %bcond_without snmp # without SNMP support
6 Summary: Network intrusion detection system
7 Summary(pl): System wykrywania intruzów w sieciach
8 Summary(pt_BR): Ferramenta de detecção de intrusos
9 Summary(ru): Snort - ÓÉÓÔÅÍÁ ÏÂÎÁÒÕÖÅÎÉÑ ÐÏÐÙÔÏË ×ÔÏÒÖÅÎÉÑ × ÓÅÔØ
10 Summary(uk): Snort - ÓÉÓÔÅÍÁ ×ÉÑ×ÌÅÎÎÑ ÓÐÒÏ ×ÔÏÒÇÎÅÎÎÑ × ÍÅÒÅÖÕ
15 Vendor: Marty Roesch <roesch@sourcefire.com>
17 Source0: http://www.snort.org/dl/%{name}-%{version}.tar.gz
18 # Source0-md5: ab5bdd0cab96fe521d11d2c6d804518f
19 Source1: http://www.snort.org/dl/signatures/%{name}rules-stable.tar.gz
20 # Source1-md5: 864eedb3122a1fe89c85669cc7d287e9
22 Source3: %{name}.logrotate
24 Patch0: %{name}-libnet1.patch
25 URL: http://www.snort.org/
26 BuildRequires: autoconf
27 BuildRequires: automake
28 BuildRequires: libnet1-devel
29 BuildRequires: libpcap-devel
30 %{?with_mysql:BuildRequires: mysql-devel}
31 %{?with_snmp:BuildRequires: net-snmp-devel >= 5.0.7}
32 BuildRequires: openssl-devel >= 0.9.7b
33 %{?with_pgsql:BuildRequires: postgresql-devel}
34 BuildRequires: zlib-devel
35 PreReq: rc-scripts >= 0.2.0
36 Requires(pre): /usr/bin/getgid
37 Requires(pre): /bin/id
38 Requires(pre): /usr/sbin/groupadd
39 Requires(pre): /usr/sbin/useradd
40 Requires(post,preun): /sbin/chkconfig
41 Requires(postun): /usr/sbin/userdel
42 Requires(postun): /usr/sbin/groupdel
43 %{?with_mysql:Provides: snort(mysql) = %{version}}
44 %{?with_pgsql:Provides: snort(pgsql) = %{version}}
45 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
47 %define _sysconfdir /etc/snort
48 %define _bindir %{_sbindir}
51 Snort is an open source network intrusion detection system, capable of
52 performing real-time traffic analysis and packet logging on IP
53 networks. It can perform protocol analysis and content
54 searching/matching in order to detect a variety of attacks and probes,
55 such as buffer overflows, stealth port scans, CGI attacks, SMB probes,
56 OS fingerprinting attempts, and much more. Snort uses a flexible rules
57 language to describe traffic that it should collect or pass, as well
58 as a detection engine that utilizes a modular plugin architecture.
59 Snort has a real- time alerting capability as well, incorporating
60 alerting mechanisms for syslog, user specified files, a UNIX socket,
61 or WinPopup messages to Windows clients using Samba's smbclient.
64 Snort to bazuj±cy na open source NIDS (network intrusion detection
65 systems) wykonuj±cy w czasie rzeczywistym analizê ruchu oraz logowanie
66 pakietów w sieciach IP. Jego mo¿liwo¶ci to analiza protoko³u oraz
67 zawarto¶ci w poszukiwaniu ró¿nego rodzaju ataków lub prób takich jak
68 przepe³nienia bufora, skanowanie portów typu stealth, ataki CGI,
69 próbkowanie SMB, OS fingerprinting i du¿o wiêcej. Snort u¿ywa
70 elastycznego jêzyka regu³ek do opisu ruchu, który nale¿y
71 przeanalizowaæ jak równie¿ silnika wykrywaj±cego, wykorzystuj±cego
72 modu³ow± architekturê. Snort umo¿liwia alarmowanie w czasie
73 rzeczywistym poprzez sysloga, osobny plik lub jako wiadomo¶æ WinPopup
74 poprzez klienta Samby: smbclient.
77 Snort é um sniffer baseado em libpcap que pode ser usado como um
78 pequeno sistema de detecção de intrusos. Tem como característica o
79 registro de pacotes baseado em regras e também pode executar uma
80 análise do protocolo, pesquisa de padrões e detectar uma variedade de
81 assinaturas de ataques, como estouros de buffer, varreduras "stealth"
82 de portas, ataques CGI, pesquisas SMB, tentativas de descobrir o
83 sistema operacional e muito mais. Possui um sistema de alerta em tempo
84 real, com alertas enviados para o syslog, um arquivo de alertas em
85 separado ou como uma mensagem Winpopup.
88 Snort - ÜÔÏ ÓÎÉÆÆÅÒ ÐÁËÅÔÏ×, ËÏÔÏÒÙÊ ÍÏÖÅÔ ÉÓÐÏÌØÚÏ×ÁÔØÓÑ ËÁË ÓÉÓÔÅÍÁ
89 ÏÂÎÁÒÕÖÅÎÉÑ ÐÏÐÙÔÏË ×ÔÏÒÖÅÎÉÑ × ÓÅÔØ. Snort ÐÏÄÄÅÒÖÉ×ÁÅÔ
90 ÐÒÏÔÏËÏÌÉÒÏ×ÁÎÉÅ ÐÁËÅÔÏ× ÎÁ ÏÓÎÏ×Å ÐÒÁ×ÉÌ, ÍÏÖÅÔ ×ÙÐÏÌÎÑÔØ ÁÎÁÌÉÚ
91 ÐÒÏÔÏËÏÌÏ×, ÐÏÉÓË × ÓÏÄÅÒÖÉÍÏÍ ÐÁËÅÔÏ×. íÏÖÅÔ ÔÁËÖÅ ÉÓÐÏÌØÚÏ×ÁÔØÓÑ ÄÌÑ
92 ÏÂÎÁÒÕÖÅÎÉÑ ÁÔÁË É "ÒÁÚ×ÅÄÏË", ÔÁËÉÈ ËÁË ÐÏÐÙÔËÉ ÁÔÁË ÔÉÐÁ
93 "ÐÅÒÅÐÏÌÎÅÎÉÅ ÂÕÆÅÒÁ", ÓËÒÙÔÏÇÏ ÓËÁÎÉÒÏ×ÁÎÉÑ ÐÏÒÔÏ×, CGI ÁÔÁË, SMB
94 ÒÁÚ×ÅÄÏË, ÐÏÐÙÔÏË ÏÂÎÁÒÕÖÅÎÉÑ ÔÉÐÁ ïó É ÍÎÏÇÏ ÄÒÕÇÏÇÏ. Snort ÍÏÖÅÔ
95 ÉÎÆÏÒÍÉÒÏ×ÁÔØ Ï ÓÏÂÙÔÉÑÈ × ÒÅÁÌØÎÏÍ ×ÒÅÍÅÎÉ, ÐÏÓÙÌÁÑ ÓÏÏÂÝÅÎÉÑ ×
96 syslog, ÏÔÄÅÌØÎÙÊ ÆÁÊÌ ÉÌÉ ËÁË WinPopup ÓÏÏÂÝÅÎÉÑ ÞÅÒÅÚ smbclient.
99 Snort - ÃÅ ÓΦÆÅÒ ÐÁËÅÔ¦×, ÝÏ ÍÏÖÅ ×ÉËÏÒÉÓÔÏ×Õ×ÁÔÉÓØ ÑË ÓÉÓÔÅÍÁ
100 ×ÉÑ×ÌÅÎÎÑ ÓÐÒÏ ×ÔÏÒÇÎÅÎØ × ÍÅÒÅÖÕ. Snort ЦÄÔÒÉÍÕ¤ ÐÒÏÔÏËÏÌÀ×ÁÎÎÑ
101 ÐÁËÅÔ¦× ÎÁ ÏÓÎÏצ ÐÒÁ×ÉÌ, ÍÏÖÅ ×ÉËÏÎÕ×ÁÔÉ ÁÎÁÌ¦Ú ÐÒÏÔÏËÏ̦×, ÐÏÛÕË Õ
102 ×ͦÓÔ¦ ÐÁËÅÔ¦×. íÏÖÅ ÔÁËÏÖ ×ÉËÏÒÉÓÔÏ×Õ×ÁÔÉÓØ ÄÌÑ ×ÉÑ×ÌÅÎÎÑ ÁÔÁË ÔÁ
103 "ÒÏÚצÄÏË", ÔÁËÉÈ ÑË ÓÐÒÏÂÉ ÁÔÁË ÔÉÐÕ "ÐÅÒÅÐÏ×ÎÅÎÎÑ ÂÕÆÅÒÁ",
104 ÐÒÉÈÏ×ÁÎÏÇÏ ÓËÁÎÕ×ÁÎÎÑ ÐÏÒÔ¦×, CGI ÁÔÁË, SMB ÒÏÚצÄÏË, ÓÐÒÏ ×ÉÑ×ÌÅÎÎÑ
105 ÔÉÐÕ ïó ÔÁ ÂÁÇÁÔÏ ¦ÎÛÏÇÏ. Snort ÍÏÖÅ ¦ÎÆÏÒÍÕ×ÁÔÉ ÐÒÏ ÐÏĦ§ × ÒÅÁÌØÎÏÍÕ
106 ÞÁÓ¦, ÎÁÄÓÉÌÁÀÞÉ ÐÏצÄÏÍÌÅÎÎÑ ÄÏ syslog, ÏËÒÅÍÏÇÏ ÆÁÊÌÕ ÞÉ ÑË WinPopup
107 ÐÏצÄÏÍÌÅÎÎÑ ÞÅÒÅÚ smbclient.
118 # we don't need libnsl, so don't use it
119 no_libnsl=yes; export no_libnsl
123 --with-libnet-includes=/usr/include/libnet1 \
124 --with%{!?with_snmp:out}-snmp \
126 --with%{!?with_pgsql:out}-postgresql \
127 --with%{!?with_mysql:out}-mysql
132 rm -rf $RPM_BUILD_ROOT
133 install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,%{name},cron.daily,logrotate.d} \
134 $RPM_BUILD_ROOT%{_var}/log/{%{name},archiv/%{name}} \
135 $RPM_BUILD_ROOT%{_datadir}/mibs/site \
136 $RPM_BUILD_ROOT%{_sysconfdir}/rules
139 DESTDIR=$RPM_BUILD_ROOT
141 install rules/*.config $RPM_BUILD_ROOT%{_sysconfdir}
142 install rules/*.rules $RPM_BUILD_ROOT%{_sysconfdir}/rules
143 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
144 install %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/%{name}
145 install %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}
148 rm -rf $RPM_BUILD_ROOT
151 if [ -z "`getgid %{name}`" ]; then
152 /usr/sbin/groupadd -g 46 -r snort 2> /dev/null || true
155 if [ -z "`id -u %{name} 2>/dev/null`" ]; then
156 /usr/sbin/useradd -u 46 -g %{name} -M -r -d %{_var}/log/%{name} -s /bin/false \
157 -c "SNORT" snort 2> /dev/null || true
161 if [ "$1" = "1" ] ; then
162 /sbin/chkconfig --add snort
164 if [ -f /var/lock/subsys/snort ]; then
165 /etc/rc.d/init.d/snort restart 1>&2
167 echo "Run \"/etc/rc.d/init.d/snort start\" to start Snort daemon."
172 if [ "$1" = "0" ] ; then
173 if [ -f /var/lock/subsys/snort ]; then
174 /etc/rc.d/init.d/snort stop 1>&2
176 /sbin/chkconfig --del snort
180 if [ "$1" = "0" ] ; then
181 /usr/sbin/userdel snort 2> /dev/null || true
182 /usr/sbin/groupdel snort 2> /dev/null || true
186 %defattr(644,root,root,755)
187 %doc doc/{AUTHORS,BUGS,CREDITS,FAQ,NEWS,README*,RULES*,TODO,USAGE}
188 %doc contrib/create* doc/*.pdf
189 %attr(755,root,root) %{_sbindir}/*
190 %attr(770,root,snort) %dir %{_var}/log/%{name}
191 %attr(770,root,snort) %dir %{_var}/log/archiv/%{name}
192 %attr(750,root,snort) %dir %{_sysconfdir}
193 %attr(750,root,snort) %dir %{_sysconfdir}/rules
194 %attr(640,root,snort) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*
195 %attr(640,root,snort) %{_sysconfdir}/rules/*
196 %attr(750,root,root) /etc/rc.d/init.d/%{name}
197 %attr(640,root,root) /etc/logrotate.d/*