Compare commits
9 Commits
3.5.1.0-1m
...
main
Author | SHA1 | Date | |
---|---|---|---|
c41cf40d1d | |||
35253be5bb | |||
d5933184ef | |||
20a403c4f9 | |||
f1ac52a0fc | |||
f9e393a624 | |||
dcbcf1cca0 | |||
6c2d791125 | |||
11ebca0e50 |
115
snort.spec
115
snort.spec
@ -5,7 +5,7 @@
|
||||
%define userid 65023
|
||||
|
||||
Name: snort
|
||||
Version: 3.5.1.0
|
||||
Version: 3.7.3.0
|
||||
Release: 1mamba
|
||||
Summary: The Open Source Intrusion Detection System
|
||||
Group: Network/Monitoring
|
||||
@ -18,22 +18,10 @@ Source1: snort-initscript
|
||||
Source2: snort-sysconfig
|
||||
Source3: snort-createmysql
|
||||
Source4: snort-createmysql-archive
|
||||
#Source5: http://www.snort.org/dl/contrib/...
|
||||
Source5: snortdb-extra.bz2
|
||||
Source6: https://www.snort.org/downloads/community/snort3-community-rules.tar.gz
|
||||
Source7: snort-conf
|
||||
License: GPL
|
||||
%if %enable_mysql
|
||||
BuildRequires: libmysql5-devel
|
||||
%endif
|
||||
%if %enable_odbc
|
||||
Requires: libodbc >= 2.2.6
|
||||
BuildRequires: libodbc-devel >= 2.2.6
|
||||
%endif
|
||||
%if %enable_postgresql
|
||||
Requires: postgresql >= 7.3.3
|
||||
BuildRequires: postgresql-devel >= 7.4-2
|
||||
%endif
|
||||
## AUTOBUILDREQ-BEGIN
|
||||
BuildRequires: glibc-devel
|
||||
BuildRequires: libatomic-devel
|
||||
@ -47,7 +35,7 @@ BuildRequires: libmnl-devel
|
||||
BuildRequires: libnuma-devel
|
||||
BuildRequires: libopenssl-devel
|
||||
BuildRequires: libpcap-devel
|
||||
BuildRequires: libpcre-devel
|
||||
BuildRequires: libpcre2-devel
|
||||
BuildRequires: libstdc++6-devel
|
||||
BuildRequires: libunwind-devel
|
||||
BuildRequires: libuuid-devel
|
||||
@ -56,6 +44,17 @@ BuildRequires: libz-devel
|
||||
BuildRequires: libdnet-devel
|
||||
BuildRequires: libdaq-devel >= 3.0.5
|
||||
BuildRequires: libluajit-devel
|
||||
%if %enable_mysql
|
||||
BuildRequires: libmysql5-devel
|
||||
%endif
|
||||
%if %enable_odbc
|
||||
Requires: libodbc >= 2.2.6
|
||||
BuildRequires: libodbc-devel >= 2.2.6
|
||||
%endif
|
||||
%if %enable_postgresql
|
||||
Requires: postgresql >= 7.3.3
|
||||
BuildRequires: postgresql-devel >= 7.4-2
|
||||
%endif
|
||||
Provides: %{_datadir}/snort/contrib/createmysql
|
||||
Provides: %{_datadir}/snort/contrib/createmysql-archive
|
||||
|
||||
@ -81,7 +80,6 @@ Snort has three primary uses.
|
||||
It can be used as a straight packet sniffer like tcpdump(1), a packet logger (useful for network traffic debugging, etc), or as a full blown network intrusion detection system.
|
||||
This package contains the static libraries, headers and source files for development.
|
||||
|
||||
%debug_package
|
||||
|
||||
%prep
|
||||
%setup -q -n snort3-%{version} -a6
|
||||
@ -89,33 +87,11 @@ This package contains the static libraries, headers and source files for develop
|
||||
|
||||
%build
|
||||
%cmake -d build \
|
||||
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 \
|
||||
-DCMAKE_INSTALL_SYSCONFDIR=%{_sysconfdir}
|
||||
|
||||
%make
|
||||
|
||||
:<< __OLD
|
||||
%configure \
|
||||
--sysconfdir=%{_sysconfdir}/snort \
|
||||
--enable-linux-smp-stat \
|
||||
--enable-smbalerts \
|
||||
%if %enable_mysql
|
||||
--with-mysql \
|
||||
%else
|
||||
--without-mysql --disable-mysql \
|
||||
%endif
|
||||
%if %enable_odbc
|
||||
--with-odbc \
|
||||
%endif
|
||||
%if %enable_postgresql
|
||||
--with-postgresql \
|
||||
%endif
|
||||
CFLAGS="%{optflags} -I%{_includedir}/tirpc"
|
||||
# --enable-sourcefire
|
||||
# --enable-perfmonitor
|
||||
# --enable-flexresp
|
||||
|
||||
%make -j1
|
||||
|
||||
%install
|
||||
[ "%{buildroot}" != / ] && rm -rf %{buildroot}
|
||||
%makeinstall -C build
|
||||
@ -123,47 +99,15 @@ This package contains the static libraries, headers and source files for develop
|
||||
install -d %{buildroot}%{_sysconfdir}/snort/{rules,preproc_rules}
|
||||
cp snort3-community-rules/*.rules %{buildroot}%{_sysconfdir}/snort/rules/
|
||||
|
||||
:<< __OLD
|
||||
#cp preproc_rules/*.rules %{buildroot}%{_sysconfdir}/snort/preproc_rules/
|
||||
#cp etc/*.conf etc/*.config etc/*.map %{buildroot}%{_sysconfdir}/snort
|
||||
|
||||
#install -D -m 755 %{SOURCE1} %{buildroot}%{_initrddir}/snort
|
||||
#install -D -m 644 %{SOURCE2} %{buildroot}%{_sysconfdir}/sysconfig/snort
|
||||
|
||||
#install -d %{buildroot}/var/log/snort
|
||||
|
||||
install -D %{SOURCE3} %{buildroot}%{_datadir}/snort/contrib/createmysql
|
||||
install -D %{SOURCE4} %{buildroot}%{_datadir}/snort/contrib/createmysql-archive
|
||||
|
||||
install -D %{SOURCE7} %{buildroot}%{_sysconfdir}/snort/snort.conf
|
||||
|
||||
#cp contrib/create* contrib/snortdb-extra.bz2 %{buildroot}%{_datadir}/snort/contrib/
|
||||
cp %{SOURCE5} %{buildroot}%{_datadir}/snort/contrib/
|
||||
#cp schemas/create_* %{buildroot}%{_datadir}/snort/contrib/
|
||||
__OLD
|
||||
|
||||
%pre
|
||||
/usr/sbin/groupadd snort -g %{groupid} 2>/dev/null
|
||||
/usr/sbin/useradd -u %{userid} -c 'Snort user' -d /dev/null -g snort \
|
||||
-s /bin/false snort 2>/dev/null
|
||||
exit 0
|
||||
|
||||
#%post
|
||||
# new install
|
||||
#if [ $1 -eq 1 ]; then
|
||||
# RANDOM_PASSWD=`/usr/bin/mkpasswd -l 10 -s 0`
|
||||
# sed -i "s|# output database: log, mysql.*|output database: log, mysql, user=snort password=$RANDOM_PASSWD dbname=snort host=localhost|" \
|
||||
# %{_sysconfdir}/snort/snort.conf
|
||||
# %{_datadir}/snort/contrib/createmysql $RANDOM_PASSWD
|
||||
# %{_datadir}/snort/contrib/createmysql-archive $RANDOM_PASSWD
|
||||
#fi
|
||||
#:
|
||||
:
|
||||
|
||||
%preun
|
||||
# erase
|
||||
if [ $1 -eq 0 ]; then
|
||||
#service snort stop 2>/dev/null
|
||||
#/sbin/chkconfig --del snort
|
||||
/usr/sbin/userdel snort 2>/dev/null
|
||||
fi
|
||||
:
|
||||
@ -174,8 +118,6 @@ if [ $1 -eq 1 ]; then
|
||||
groupadd snort -g %{groupid} 2>/dev/null
|
||||
/usr/sbin/useradd -u %{userid} -c 'Snort user' -d /dev/null -g snort \
|
||||
-s /bin/false snort 2>/dev/null
|
||||
#/sbin/chkconfig snort
|
||||
#[ $? -eq 0 ] && service snort restart
|
||||
fi
|
||||
:
|
||||
|
||||
@ -211,6 +153,33 @@ fi
|
||||
%{_libdir}/pkgconfig/snort.pc
|
||||
|
||||
%changelog
|
||||
* Tue Apr 22 2025 Automatic Build System <autodist@openmamba.org> 3.7.3.0-1mamba
|
||||
- automatic version update by autodist
|
||||
|
||||
* Sat Apr 05 2025 Automatic Build System <autodist@openmamba.org> 3.7.2.0-1mamba
|
||||
- automatic version update by autodist
|
||||
|
||||
* Sun Mar 16 2025 Automatic Build System <autodist@openmamba.org> 3.7.1.0-1mamba
|
||||
- automatic version update by autodist
|
||||
|
||||
* Tue Feb 18 2025 Automatic Build System <autodist@openmamba.org> 3.7.0.0-1mamba
|
||||
- automatic version update by autodist
|
||||
|
||||
* Thu Feb 06 2025 Automatic Build System <autodist@openmamba.org> 3.6.3.0-1mamba
|
||||
- automatic version update by autodist
|
||||
|
||||
* Mon Jan 27 2025 Automatic Build System <autodist@openmamba.org> 3.6.2.0-1mamba
|
||||
- automatic version update by autodist
|
||||
|
||||
* Tue Dec 31 2024 Automatic Build System <autodist@openmamba.org> 3.6.1.0-1mamba
|
||||
- automatic version update by autodist
|
||||
|
||||
* Thu Dec 05 2024 Automatic Build System <autodist@openmamba.org> 3.6.0.0-1mamba
|
||||
- automatic version update by autodist
|
||||
|
||||
* Wed Nov 20 2024 Automatic Build System <autodist@openmamba.org> 3.5.2.0-1mamba
|
||||
- automatic version update by autodist
|
||||
|
||||
* Tue Nov 12 2024 Automatic Build System <autodist@openmamba.org> 3.5.1.0-1mamba
|
||||
- automatic version update by autodist
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user