From 18299011455ff5c9f99b7d5d47372a1061a32709 Mon Sep 17 00:00:00 2001 From: Tom Callaway Date: Fri, 1 Jul 2005 16:27:11 +0000 Subject: [PATCH] Resolve blockers that Chris Ricker pointed out. --- ebtables.spec | 23 ++++++++++++++++++++--- ebtables.sysv | 10 ++++++---- 2 files changed, 26 insertions(+), 7 deletions(-) diff --git a/ebtables.spec b/ebtables.spec index 4f1b3bd..95eafa8 100644 --- a/ebtables.spec +++ b/ebtables.spec @@ -1,6 +1,6 @@ Name: ebtables Version: 2.0.6 -Release: 4%{?dist} +Release: 5%{?dist} Summary: Ethernet Bridge frame table administration tool License: GPL Group: System Environment/Base @@ -10,12 +10,17 @@ Source1: ebtables.sysv Patch0: ebtables-2.0.6-gcc34.patch Patch1: ebtables-2.0.6-gcc4.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) +PreReq: /sbin/chkconfig +PreReq: /sbin/service %description -Ethernet bridge tables is a firewalling tool to transparantly filter network +Ethernet bridge tables is a firewalling tool to transparently filter network traffic passing a bridge. The filtering possibilities are limited to link layer filtering and some basic filtering on higher network layers. +This tool is the userspace control for the bridge and ebtables kernel +components (built by default in Fedora Core kernels). + The ebtables tool can be used together with the other Linux filtering tools, like iptables. There are no known incompatibility issues. @@ -47,7 +52,9 @@ if [ $1 -eq 0 ]; then fi %postun -/sbin/service ebtables condrestart &>/dev/null || : +if [ $1 -ge 1 ] + /sbin/service ebtables condrestart &> /dev/null || : +fi %files %defattr(-, root, root, 0755) @@ -56,10 +63,20 @@ fi %config(noreplace) %{_sysconfdir}/ethertypes %{_initrddir}/ebtables /sbin/ebtables +%ghost %{_sysconfdir}/ebtables.filter +%ghost %{_sysconfdir}/ebtables.nat +%ghost %{_sysconfdir}/ebtables.broute %changelog +* Fri Jul 1 2005 Tom "spot" Callaway 2.0.6-5 +- fix sysv file + * Fri Jul 1 2005 Tom "spot" Callaway 2.0.6-4 - remove INSTALL file +- add some text to description, correct typos +- fix %postun +- add PreReqs +- add %ghost config files * Tue May 31 2005 Tom "spot" Callaway 2.0.6-3 - reworked for Fedora Extras diff --git a/ebtables.sysv b/ebtables.sysv index 25e81d3..aa51934 100644 --- a/ebtables.sysv +++ b/ebtables.sysv @@ -10,7 +10,7 @@ # # config: /etc/sysconfig/ebtables.filter # config: /etc/sysconfig/ebtables.nat -# config: /etc/sysconfig/ebtables.route +# config: /etc/sysconfig/ebtables.broute source /etc/init.d/functions source /etc/sysconfig/network @@ -27,6 +27,8 @@ RETVAL_BROUTE=0 prog="ebtables" desc="Ethernet bridge filtering" +lockfile=/var/lock/subsys/$prog + initialize() { # Initialize $TYPE tables echo -n $" $TYPE tables: " @@ -68,7 +70,7 @@ start() { RETVAL=`expr $RETVAL_BROUTE + $RETVAL_NAT + $RETVAL_FILTER` if [ $RETVAL -eq 0 ]; then - rm -f /var/lock/subsys/$prog + touch $lockfile fi echo @@ -87,7 +89,7 @@ stop() { if [ $RETVAL -eq 0 ]; then success "$prog shutdown" - rm -f /var/lock/subsys/$prog + rm -f $lockfile else failure "$prog shutdown" fi @@ -126,7 +128,7 @@ case "$1" in restart ;; condrestart) - [ -e /var/lock/subsys/$prog ] && restart + [ -e $lockfile ] && restart RETVAL=$? ;; save)