]>
Commit | Line | Data |
---|---|---|
e591aab5 JR |
1 | Summary: ULOGD - the Userspace Logging Daemon for iptables |
2 | Name: ulogd | |
57154dc8 | 3 | Version: 0.95 |
cfdad27b | 4 | Release: 2 |
e591aab5 JR |
5 | License: GPL |
6 | Group: Networking/Daemons | |
264b4e4b | 7 | Group(de): Netzwerkwesen/Server |
e591aab5 JR |
8 | Group(pl): Sieciowe/Serwery |
9 | Source0: ftp://ftp.sunbeam.franken.de/pub/netfilter/%{name}-%{version}.tar.gz | |
264b4e4b | 10 | Source1: %{name}.init |
11 | Source2: %{name}.sysconfig | |
12 | Source3: %{name}.logrotate | |
13 | Source4: %{name}.conf | |
e591aab5 JR |
14 | Patch0: %{name}-DESTDIR.patch |
15 | BuildRequires: sgml-tools | |
16 | BuildRequires: sgmls | |
17 | BuildRequires: mysql-devel | |
18 | #Requires: kernel >= 2.4.0test9 | |
19 | Requires: iptables | |
cfdad27b | 20 | Prereq: /sbin/chkconfig |
e591aab5 JR |
21 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
22 | ||
23 | %define _sysconfdir /etc | |
24 | ||
25 | %description | |
264b4e4b | 26 | This packages is intended for passing packets from the kernel to |
27 | userspace to do some logging there. It should work like that: | |
e591aab5 JR |
28 | |
29 | - Register a target called ULOG with netfilter | |
30 | - if the target is hit: | |
264b4e4b | 31 | - send the packet out using netlink multicast facility |
32 | - return NF_ACCEPT immediately | |
e591aab5 JR |
33 | |
34 | %package mysql | |
35 | Summary: Mysql plugin for ulogd | |
36 | Group: Networking/Daemons | |
264b4e4b | 37 | Group(de): Netzwerkwesen/Server |
e591aab5 JR |
38 | Group(pl): Sieciowe/Serwery |
39 | Requires: mysql | |
40 | Obsoletes: iptables-ulogd-mysql | |
41 | ||
42 | %description mysql | |
43 | mysql plugin for ulogd | |
44 | ||
45 | %prep | |
46 | %setup -q | |
47 | %patch0 -p1 | |
48 | ||
49 | %build | |
264b4e4b | 50 | %configure \ |
51 | --with-mysql | |
e591aab5 JR |
52 | %{__make} |
53 | ||
54 | %install | |
55 | rm -rf $RPM_BUILD_ROOT | |
c6e1358b | 56 | install -d $RPM_BUILD_ROOT{%{_sbindir},/etc/{sysconfig,logrotate.d,rc.d/init.d}} \ |
264b4e4b | 57 | $RPM_BUILD_ROOT/var/log |
e591aab5 JR |
58 | |
59 | %{__make} install DESTDIR=$RPM_BUILD_ROOT | |
60 | ||
264b4e4b | 61 | install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/ulogd |
62 | install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/ulogd | |
63 | install %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/ulogd | |
e591aab5 JR |
64 | install %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/ |
65 | ||
66 | gzip -9nf Changes doc/*.{ps,txt,table} | |
67 | ||
68 | touch $RPM_BUILD_ROOT/var/log/ulogd{,.pktlog} | |
69 | ||
70 | %clean | |
71 | rm -rf $RPM_BUILD_ROOT | |
72 | ||
73 | %post | |
74 | if [ ! -f /var/log/ulogd ]; then | |
75 | touch /var/log/ulogd{,.pktlog} | |
76 | chmod 640 /var/log/ulogd{,.pktlog} | |
77 | fi | |
b0ff08b6 | 78 | DESC="ulogd daemon"; %chkconfig_add |
e591aab5 JR |
79 | |
80 | %preun | |
b0ff08b6 | 81 | %chkconfig_del |
e591aab5 JR |
82 | |
83 | %files | |
84 | %defattr(644,root,root,755) | |
85 | %doc Changes.gz doc/*.{ps,txt}.gz | |
86 | %attr(640,root,root) %config(noreplace) %verify(not mtime md5 size) /etc/sysconfig/ulogd | |
264b4e4b | 87 | %attr(640,root,root) %config(noreplace) %verify(not mtime md5 size) %{_sysconfdir}/ulogd.conf |
e591aab5 JR |
88 | %attr(640,root,root) /etc/logrotate.d/ulogd |
89 | %attr(754,root,root) /etc/rc.d/init.d/ulogd | |
90 | ||
91 | %attr(755,root,root) %{_sbindir}/* | |
92 | %attr(755,root,root) %{_libdir}/ulogd/ulogd_[BLOP]*.so | |
93 | ||
94 | %attr(640,root,root) %ghost /var/log/* | |
95 | ||
96 | %files mysql | |
264b4e4b | 97 | %defattr(644,root,root,755) |
e591aab5 JR |
98 | %doc doc/mysql* |
99 | %attr(755,root,root) %{_libdir}/ulogd/ulogd_MYSQL.so |