78273e7
Summary: Intrusion Detection System
78273e7
Name: suricata
9faaf5c
Version: 4.0.7
4f5bf80
Release: 1%{?dist}
bf962db
License: GPLv2
78273e7
Group: Applications/Internet
5b94559
URL: http://suricata-ids.org/
f3961e6
Source0:  http://downloads.suricata-ids.org/%{name}-%{version}.tar.gz
a5bb759
Source1: suricata.service
78273e7
Source2: suricata.sysconfig
78273e7
Source3: suricata.logrotate
a5bb759
Source4: fedora.notes
7344e7d
Source5: suricata-tmpfiles.conf
715e2a7
90a2c90
# Irrelevant docs are getting installed, drop them
715e2a7
Patch1: suricata-2.0.9-docs.patch
7fe3cf7
# liblua is not named correctly in epel 7.
7fe3cf7
Patch2: suricata-2.0.2-lua.patch
715e2a7
d4cf4de
BuildRequires: gcc
1d67f86
BuildRequires: gcc-c++
4dbb303
BuildRequires: libyaml-devel
78273e7
BuildRequires: libnfnetlink-devel libnetfilter_queue-devel libnet-devel
5a177ab
BuildRequires: zlib-devel libpcap-devel pcre-devel libcap-ng-devel
d1b4434
BuildRequires: nspr-devel nss-devel nss-softokn-devel file-devel
5b94559
BuildRequires: jansson-devel GeoIP-devel python2-devel lua-devel
78273e7
BuildRequires: autoconf automake libtool
2ae3a89
BuildRequires: systemd
cd5c89d
BuildRequires: hiredis-devel
cd5c89d
BuildRequires: libevent-devel
cd5c89d
BuildRequires: libprelude-devel
cd5c89d
BuildRequires: pkgconfig(gnutls)
7eec7f8
715e2a7
%if 0%{?fedora} >= 25
7eec7f8
%ifarch x86_64
7eec7f8
BuildRequires: hyperscan-devel
715e2a7
Requires: ragel
7eec7f8
%endif
7eec7f8
%endif
7eec7f8
f910ca4
Requires(pre): /usr/sbin/useradd
5b94559
Requires(post): systemd
5b94559
Requires(preun): systemd
5b94559
Requires(postun): systemd
78273e7
78273e7
%description
78273e7
The Suricata Engine is an Open Source Next Generation Intrusion
78273e7
Detection and Prevention Engine. This engine is not intended to
78273e7
just replace or emulate the existing tools in the industry, but
78273e7
will bring new ideas and technologies to the field. This new Engine
78273e7
supports Multi-threading, Automatic Protocol Detection (IP, TCP,
78273e7
UDP, ICMP, HTTP, TLS, FTP and SMB! ), Gzip Decompression, Fast IP
69e67b2
Matching, and GeoIP identification.
78273e7
78273e7
%prep
78273e7
%setup -q
a5bb759
install -m 644 %{SOURCE4} doc/
d6cb842
%patch1 -p1
7fe3cf7
%if 0%{?rhel} == 7
e73eca8
%patch2 -p1
7fe3cf7
%endif
715e2a7
78273e7
autoreconf -fv --install
78273e7
78273e7
%build
cd5c89d
%configure --enable-gccprotect --enable-pie --disable-gccmarch-native --disable-coccinelle --enable-nfqueue --enable-af-packet --with-libnspr-includes=/usr/include/nspr4 --with-libnss-includes=/usr/include/nss3 --enable-jansson --enable-geoip --enable-lua --enable-hiredis --enable-prelude
2ae3a89
715e2a7
%make_build
78273e7
78273e7
%install
5b94559
make DESTDIR="%{buildroot}" "bindir=%{_sbindir}" install
78273e7
78273e7
# Setup etc directory
2ae3a89
mkdir -p %{buildroot}%{_sysconfdir}/%{name}/rules
2ae3a89
install -m 600 rules/*.rules %{buildroot}%{_sysconfdir}/%{name}/rules
2ae3a89
install -m 600 *.config %{buildroot}%{_sysconfdir}/%{name}
2ae3a89
install -m 600 suricata.yaml %{buildroot}%{_sysconfdir}/%{name}
5b94559
mkdir -p %{buildroot}%{_unitdir}
5b94559
install -m 0644 %{SOURCE1} %{buildroot}%{_unitdir}/
5b94559
mkdir -p %{buildroot}%{_sysconfdir}/sysconfig
2ae3a89
install -m 0755 %{SOURCE2} %{buildroot}%{_sysconfdir}/sysconfig/%{name}
78273e7
715e2a7
# Set up logging
2ae3a89
mkdir -p %{buildroot}/%{_var}/log/%{name}
2ae3a89
mkdir -p %{buildroot}%{_sysconfdir}/logrotate.d
2ae3a89
install -m 644 %{SOURCE3} %{buildroot}%{_sysconfdir}/logrotate.d/%{name}
78273e7
78273e7
# Remove a couple things so they don't get picked up
5b94559
rm -rf %{buildroot}%{_includedir}
5b94559
rm -f %{buildroot}%{_libdir}/libhtp.la
5b94559
rm -f %{buildroot}%{_libdir}/libhtp.a
5b94559
rm -f %{buildroot}%{_libdir}/libhtp.so
5b94559
rm -rf %{buildroot}%{_libdir}/pkgconfig
78273e7
7344e7d
# Setup tmpdirs
5b94559
mkdir -p %{buildroot}%{_tmpfilesdir}
5b94559
install -m 0644 %{SOURCE5} %{buildroot}%{_tmpfilesdir}/%{name}.conf
7344e7d
mkdir -p %{buildroot}/run
7344e7d
install -d -m 0755 %{buildroot}/run/%{name}/
7344e7d
78273e7
%check
78273e7
make check
78273e7
4dbb303
%pre
4dbb303
getent passwd suricata >/dev/null || useradd -r -M -s /sbin/nologin suricata
4dbb303
4dbb303
%post
69e67b2
/sbin/ldconfig
c778508
%systemd_post suricata.service
78273e7
78273e7
%preun
c778508
%systemd_preun suricata.service
78273e7
a5bb759
%postun
69e67b2
/sbin/ldconfig
c778508
%systemd_postun_with_restart suricata.service
78273e7
78273e7
%files
2ae3a89
%doc doc/Basic_Setup.txt
a5bb759
%doc doc/Setting_up_IPSinline_for_Linux.txt doc/fedora.notes
2ae3a89
%{!?_licensedir:%global license %%doc}
2ae3a89
%license COPYING
09a0253
%attr(644,root,root) %{_mandir}/man1/*
78273e7
%{_sbindir}/suricata
69e67b2
%{_bindir}/suricatasc
72488dc
%{_libdir}/libhtp*
5b94559
%{python2_sitelib}/suricatasc*.egg-info
5b94559
%{python2_sitelib}/suricatasc/*
2ae3a89
%config(noreplace) %attr(-,suricata,-) %{_sysconfdir}/%{name}/suricata.yaml
2ae3a89
%config(noreplace) %attr(-,suricata,-) %{_sysconfdir}/%{name}/*.config
2ae3a89
%config(noreplace) %attr(-,suricata,-) %{_sysconfdir}/%{name}/rules/*.rules
2ae3a89
%config(noreplace) %attr(0600,suricata,root) %{_sysconfdir}/sysconfig/%{name}
8b8b63d
%attr(644,root,root) %{_unitdir}/suricata.service
2ae3a89
%config(noreplace) %attr(644,root,root) %{_sysconfdir}/logrotate.d/%{name}
2ae3a89
%attr(750,suricata,root) %dir %{_var}/log/%{name}
2ae3a89
%attr(750,suricata,root) %dir %{_sysconfdir}/%{name}
2ae3a89
%attr(750,suricata,root) %dir %{_sysconfdir}/%{name}/rules
09a0253
%attr(750,suricata,root) %dir /run/%{name}/
7344e7d
%{_tmpfilesdir}/%{name}.conf
78273e7
78273e7
%changelog
9faaf5c
* Thu Mar 07 2019 Steve Grubb <sgrubb@redhat.com> 4.0.7-1
9faaf5c
- Upstream bugfix update
9faaf5c
4f5bf80
* Tue Nov 06 2018 Steve Grubb <sgrubb@redhat.com> - 4.0.6-1
4f5bf80
- New upstream bugfix release
4f5bf80
- Fixes CVE-2018-18956 Segmentation fault in the ProcessMimeEntity function
4f5bf80
bbdc86b
* Mon Aug 13 2018 Steve Grubb <sgrubb@redhat.com> - 4.0.5-3
7fe3cf7
- Consolidate branches so that everything is in sync (#1614935)
7fe3cf7
3cc8966
* Fri Aug 10 2018 Jason Taylor <jtfas90@gmail.com> 4.0.5-2
3cc8966
- fixes bz#1614935
3cc8966
0a83994
* Wed Jul 18 2018 Jason Taylor <jtfas90@gmail.com> - 4.0.5-1
0a83994
- upstream security fix release
ca77bdc
- addresses CVE-2018-10242, CVE-2018-10243, CVE-2018-10244
ca77bdc
df98bb1
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 4.0.4-3
df98bb1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
df98bb1
6780932
* Mon Jul 09 2018 Jason Taylor <jtfas90@gmail.com> - 4.0.4-2
6780932
- bumped release for build against hyperscan 5.0.0
6780932
1d67f86
* Mon Jul 09 2018 Jason Taylor <jtfas90@gmail.com> - 4.0.4-1
1d67f86
- added gcc-c++ buildrequires
1d67f86
59ba250
* Thu Feb 15 2018 Jason Taylor <jtfas90@gmail.com> - 4.0.4-1
da892c6
- fixes bz#1543250 and bz#1543251
da892c6
- multiple upstream bugfixes
da892c6
5eb1dd3
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 4.0.3-3
5eb1dd3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
cd5c89d
59ba250
* Mon Dec 11 2017 Jason Taylor <jtfas90@gmail.com> 4.0.3-2
a15b3fc
- Added prelude support
a15b3fc
ae1debc
* Fri Dec 08 2017 Jason Taylor <jtfas90@gmail.com> 4.0.3-1
f25bef9
- Upstream bugfix release
f25bef9
a85ae7e
* Wed Oct 18 2017 Steve Grubb <sgrubb@redhat.com> 4.0.1-1
a85ae7e
- Upstream bugfix update
a85ae7e
a7a5868
* Tue Sep 26 2017 Steve Grubb <sgrubb@redhat.com> 4.0.0-2
a7a5868
- Make suricata user own /run/suricata (#1396150)
a7a5868
715e2a7
* Mon Jul 31 2017 Jason Taylor <jtfas90@gmail.com> 4.0.0-1
715e2a7
- Latest upstream major release
715e2a7
- Build now has hyperscan and redis support
7eec7f8
e65ca7a
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.2.3-2
e65ca7a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
bbdc86b
>>>>>>> master
3781f6d
72488dc
* Thu Jul 13 2017 Jason Taylor <jtfas90@gmail.com> 3.2.3-1
72488dc
- Upstream bugfix update
72488dc
546e360
* Wed Jun 07 2017 Steve Grubb <sgrubb@redhat.com> 3.2.2-1
546e360
- Upstream bugfix update
546e360
41a7888
* Wed Feb 15 2017 Steve Grubb <sgrubb@redhat.com> 3.2.1-1
41a7888
- Upstream security update
41a7888
09a0253
* Mon Feb 13 2017 Steve Grubb <sgrubb@redhat.com> 3.2-1
09a0253
- New upstream feature release
09a0253
- Rotate /var/log/suricata/eve.json (#1396151)
09a0253
- Fix ownership of /run/suricata (#1396150)
09a0253
efe14bb
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.1.3-2
efe14bb
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
efe14bb
f36ec94
* Tue Nov 01 2016 Steve Grubb <sgrubb@redhat.com> 3.1.3-1
f36ec94
- New upstream bug fix release
f36ec94
f3961e6
* Wed Sep 07 2016 Steve Grubb <sgrubb@redhat.com> 3.1.2-1
f3961e6
- New upstream bug fix release
f3961e6
751bbd4
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.1.1-2
751bbd4
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
751bbd4
086d75b
* Wed Jul 13 2016 Steve Grubb <sgrubb@redhat.com> 3.1.1-1
088bfec
- New upstream bug fix release
088bfec
5ff26f2
* Wed Jun 22 2016 Steve Grubb <sgrubb@redhat.com> 3.1-1
5ff26f2
- New upstream bug fix release
5ff26f2
e2787e4
* Mon Apr 04 2016 Steve Grubb <sgrubb@redhat.com> 3.0.1-1
e2787e4
- New upstream bug fix release
e2787e4
eddc26b
* Wed Mar 16 2016 Steve Grubb <sgrubb@redhat.com> 3.0-2
eddc26b
- Fixed Bug 1227085 - Have Suricata start after the network is online
eddc26b
2ae3a89
* Mon Mar 07 2016 Steve Grubb <sgrubb@redhat.com> 3.0-1
2ae3a89
- New upstream bug fix release
2ae3a89
4dbb303
* Wed Feb 10 2016 Peter Schiffer <pschiffe@redhat.com> 2.0.11-3
4dbb303
- Run suricata under suricata user
4dbb303
f7cc661
* Fri Feb 05 2016 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.11-2
f7cc661
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
f7cc661
4c74ec6
* Mon Dec 28 2015 Steve Grubb <sgrubb@redhat.com> 2.0.11-1
4c74ec6
- New upstream bug fix release
4c74ec6
0623dbf
* Wed Nov 25 2015 Steve Grubb <sgrubb@redhat.com> 2.0.10-1
0623dbf
- New upstream bug fix release
0623dbf
64dceae
* Sat Oct 03 2015 Steve Grubb <sgrubb@redhat.com> 2.0.9-1
64dceae
- New upstream bug fix release
64dceae
3dc63e0
* Fri Jun 19 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.8-2
3dc63e0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
3dc63e0
c59f04a
* Wed May 06 2015 Steve Grubb <sgrubb@redhat.com> 2.0.8-1
00b3501
- New upstream security bug fix release
00b3501
88f8f43
* Thu Feb 26 2015 Steve Grubb <sgrubb@redhat.com> 2.0.7-1
88f8f43
- New upstream security bug fix release for CVE-2015-0928
88f8f43
521c5b4
* Thu Jan 15 2015 Steve Grubb <sgrubb@redhat.com> 2.0.6-1
521c5b4
- New upstream bug fix release
521c5b4
- Don't use the system libhtp library
521c5b4
affdefa
* Fri Dec 12 2014 Steve Grubb <sgrubb@redhat.com> 2.0.5-1
affdefa
- New upstream bug fix release
affdefa
- Use the system libhtp library
affdefa
90398e9
* Wed Sep 24 2014 Steve Grubb <sgrubb@redhat.com> 2.0.4-1
90398e9
- New upstream bug fix release
90398e9
- Fixes CVE-2014-6603 out-of-bounds access in SSH parser
90398e9
8e88615
* Mon Aug 18 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.3-2
8e88615
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
8e88615
61055d5
* Fri Aug 08 2014 Steve Grubb <sgrubb@redhat.com> 2.0.3-1
61055d5
- New upstream bug fix release
61055d5
5b94559
* Sat Jun 28 2014 Steve Grubb <sgrubb@redhat.com> 2.0.2-2
5b94559
- Specfile cleanups (#1113413)
5b94559
e73eca8
* Wed Jun 25 2014 Steve Grubb <sgrubb@redhat.com> 2.0.2-1
e73eca8
- New upstream bug fix release
e73eca8
- Enable liblua support
e73eca8
d7d41f7
* Sun Jun 08 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.1-2
d7d41f7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
d7d41f7
4429907
* Wed May 21 2014 Steve Grubb <sgrubb@redhat.com> 2.0.1-1
4429907
- New upstream bug fix release
4429907
d1b4434
* Wed Mar 26 2014 Steve Grubb <sgrubb@redhat.com> 2.0-1
d1b4434
- Major new upstream release with new features
d1b4434
4ade0ce
* Tue Jan 21 2014 Dan Horák <dan[at]danny.cz> 1.4.7-3
4ade0ce
- luajit available only on selected arches
4ade0ce
6cbe8fa
* Sat Jan 11 2014 Steve Grubb <sgrubb@redhat.com> 1.4.7-2
6cbe8fa
- Enable luajit support
6cbe8fa
083e75d
* Wed Dec 18 2013 Steve Grubb <sgrubb@redhat.com> 1.4.7-1
083e75d
- New upstream bug fix release
083e75d
7344e7d
* Fri Oct 04 2013 Steve Grubb <sgrubb@redhat.com> 1.4.6-1
7344e7d
- New upstream bug fix release
7344e7d
ee47642
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.4.3-3
ee47642
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
ee47642
8b8b63d
* Fri Jun 21 2013 Steve Grubb <sgrubb@redhat.com> 1.4.3-2
8b8b63d
- Drop prelude support
8b8b63d
76588e1
* Fri Jun 21 2013 Steve Grubb <sgrubb@redhat.com> 1.4.3-1
76588e1
- New upstream bug fix release
76588e1
ef8356e
* Mon Jun 03 2013 Steve Grubb <sgrubb@redhat.com> 1.4.2-1
ef8356e
- New upstream bug fix release
ef8356e
aad7f94
* Sun Mar 10 2013 Steve Grubb <sgrubb@redhat.com> 1.4.1-1
69e67b2
- New upstream bugfix release
69e67b2
- Enable libgeoip support
69e67b2
- Switch to stack-protector-all
69e67b2
ebabd26
* Fri Feb 15 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.4-2
ebabd26
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
ebabd26
281f947
* Thu Dec 20 2012 Steve Grubb <sgrubb@redhat.com> 1.4-1
281f947
- New upstream feature enhancement release
281f947
73a0f2c
* Thu Dec 06 2012 Steve Grubb <sgrubb@redhat.com> 1.3.5-1
73a0f2c
- New upstream bugfix release
73a0f2c
cd3f8ba
* Tue Nov 27 2012 Steve Grubb <sgrubb@redhat.com> 1.3.4-1
cd3f8ba
- New upstream release
cd3f8ba
9f71bbc
* Mon Nov 05 2012 Steve Grubb <sgrubb@redhat.com> 1.3.3-1
9f71bbc
- New upstream release
9f71bbc
2afa239
* Tue Oct 09 2012 Steve Grubb <sgrubb@redhat.com> 1.3.2-2
2afa239
- Add nss-devel build require and systemd macros
2afa239
65adc7c
* Mon Oct 08 2012 Steve Grubb <sgrubb@redhat.com> 1.3.2-1
65adc7c
- New upstream release
65adc7c
a5bb759
* Sat Aug 25 2012 Steve Grubb <sgrubb@redhat.com> 1.3.1-1
a5bb759
- New upstream release
a5bb759
- Switch startup to use systemd
637e308
62eba71
* Fri Jul 06 2012 Steve Grubb <sgrubb@redhat.com> 1.3-1
62eba71
- New upstream release
62eba71
2a8e290
* Fri Mar 30 2012 Jon Ciesla <limburgher@gmail.com> - 1.2.1-3
2a8e290
- Rebuild for updated libnet.
2a8e290
4c6809b
* Fri Feb 10 2012 Petr Pisar <ppisar@redhat.com> - 1.2.1-2
4c6809b
- Rebuild against PCRE 8.30
4c6809b
5512a33
* Thu Feb 02 2012 Steve Grubb <sgrubb@redhat.com> 1.2.1-1
5512a33
- New upstream release
5512a33
03c1e15
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.1-3
03c1e15
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
03c1e15
a60c033
* Thu Dec 22 2011 Steve Grubb <sgrubb@redhat.com> 1.1.1-2
a60c033
- Enable AF_PACKET support
a60c033
bf962db
* Wed Dec 07 2011 Steve Grubb <sgrubb@redhat.com> 1.1.1-1
bf962db
- New upstream release
bf962db
7344e7d
* Mon Jul 25 2011 Steve Grubb <sgrubb@redhat.com> 1.0.5-1
d6cb842
- New upstream release
d6cb842
b9b4a8d
* Fri Jun 24 2011 Steve Grubb <sgrubb@redhat.com> 1.0.4-1
b9b4a8d
- New upstream release
b9b4a8d
c133104
* Thu Apr 28 2011 Dan Horák <dan[at]danny.cz> 1.0.3-2
c133104
- don't override -march set by the buildsystem (fixes build on non-x86)
c133104
32bac31
* Sat Apr 23 2011 Steve Grubb <sgrubb@redhat.com> 1.0.3-1
32bac31
- New upstream release
32bac31
aa3d515
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.2-2
aa3d515
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
aa3d515
Steve d33d467
* Wed Nov 10 2010 Steve Grubb <sgrubb@redhat.com> 1.0.2-1
Steve 2008d76
- New upstream release (#651978)
Steve d33d467
66af920
* Thu Jul 01 2010 Steve Grubb <sgrubb@redhat.com> 1.0.0-1
66af920
- New upstream release
66af920
5a177ab
* Fri May 07 2010 Steve Grubb <sgrubb@redhat.com> 0.9.0-1
5a177ab
- New upstream release
5a177ab
f510298
* Tue Apr 20 2010 Steve Grubb <sgrubb@redhat.com> 0.8.2-1
f510298
- New upstream release
f510298
78273e7
* Sat Feb 27 2010 Steve Grubb <sgrubb@redhat.com> 0.8.1-1
78273e7
- Initial packaging
78273e7