|
| 1 | +Summary: An easy to use but powerfull iptables stateful firewall |
| 2 | +Name: firehol |
| 3 | +Version: MYVERSION |
| 4 | +Release: MYRELEASE |
| 5 | +Copyright: GPL |
| 6 | +Group: Applications/Internet |
| 7 | +Source: %{name}-%{version}.tar.bz2 |
| 8 | +URL: http://firehol.sourceforge.net |
| 9 | +Vendor: Costa Tsaousis |
| 10 | +Packager: Costa Tsaousis |
| 11 | +BuildArchitectures: noarch |
| 12 | +BuildRoot: %{_tmppath}/%{name}-buildroot |
| 13 | + |
| 14 | +requires: bash >= 2.04 |
| 15 | +requires: fileutils >= 4.0.36 |
| 16 | +requires: gawk >= 3.0 |
| 17 | +requires: grep >= 2.4.2 |
| 18 | +requires: iproute >= 2.2.4 |
| 19 | +requires: iptables >= 1.2.4 |
| 20 | +requires: kernel >= 2.4 |
| 21 | +requires: less |
| 22 | +requires: modutils >= 2.4.13 |
| 23 | +requires: net-tools >= 1.57 |
| 24 | +requires: sed >= 3.02 |
| 25 | +requires: sh-utils >= 2.0 |
| 26 | +requires: textutils >= 2.0.11 |
| 27 | +requires: util-linux >= 2.11 |
| 28 | + |
| 29 | +%description |
| 30 | +FireHOL uses an extremely simple but powerfull way to define |
| 31 | +firewall rules which it turns into complete stateful iptables |
| 32 | +firewalls. |
| 33 | +FireHOL is a generic firewall generator, meaning that you can |
| 34 | +design any kind of local or routing stateful packet filtering |
| 35 | +firewalls with ease. |
| 36 | + |
| 37 | +Install FireHOL if you want an easy way to configure stateful |
| 38 | +packet filtering firewalls on Linux hosts and routers. |
| 39 | + |
| 40 | +You can run FireHOL with the 'helpme' argument, to get a |
| 41 | +configuration file for the system run, which you can modify |
| 42 | +according to your needs. |
| 43 | + |
| 44 | +The default configuration file will allow only client traffic |
| 45 | +on all interfaces. |
| 46 | + |
| 47 | +%prep |
| 48 | +%{__rm} -rf %{buildroot} |
| 49 | +%setup |
| 50 | + |
| 51 | +%build |
| 52 | + |
| 53 | +%install |
| 54 | +mkdir -p %{buildroot}/etc/firehol/examples |
| 55 | +mkdir -p %{buildroot}/etc/firehol/services |
| 56 | +test -f /etc/firehol.conf -a ! -f /etc/firehol/firehol.conf && mv -f /etc/firehol.conf /etc/firehol/firehol.conf |
| 57 | +mkdir -p %{buildroot}/etc/init.d |
| 58 | +install -m 750 firehol.sh %{buildroot}/etc/init.d/firehol |
| 59 | +install -m 640 examples/client-all.conf %{buildroot}/etc/firehol/firehol.conf |
| 60 | +mkdir -p %{buildroot}/%{_mandir}/man1 |
| 61 | +mkdir -p %{buildroot}/%{_mandir}/man5 |
| 62 | +gzip -9 man/firehol.1 |
| 63 | +gzip -9 man/firehol.conf.5 |
| 64 | +install -m 644 man/firehol.1.gz %{buildroot}/%{_mandir}/man1/firehol.1.gz |
| 65 | +install -m 644 man/firehol.conf.5.gz %{buildroot}/%{_mandir}/man5/firehol.conf.5.gz |
| 66 | +install -m 644 examples/home-adsl.conf %{buildroot}/etc/firehol/examples/home-adsl.conf |
| 67 | +install -m 644 examples/home-dialup.conf %{buildroot}/etc/firehol/examples/home-dialup.conf |
| 68 | +install -m 644 examples/office.conf %{buildroot}/etc/firehol/examples/office.conf |
| 69 | +install -m 644 examples/server-dmz.conf %{buildroot}/etc/firehol/examples/server-dmz.conf |
| 70 | +install -m 644 examples/client-all.conf %{buildroot}/etc/firehol/examples/client-all.conf |
| 71 | +install -m 644 examples/lan-gateway.conf %{buildroot}/etc/firehol/examples/lan-gateway.conf |
| 72 | + |
| 73 | +%pre |
| 74 | + |
| 75 | +%post |
| 76 | +if [ -f /etc/firehol.conf -a ! -f /etc/firehol/firehol.conf ] |
| 77 | +then |
| 78 | + mv -f /etc/firehol.conf /etc/firehol/firehol.conf |
| 79 | + echo |
| 80 | + echo |
| 81 | + echo "FireHOL has now its configuration in /etc/firehol/firehol.conf" |
| 82 | + echo "Your existing configuration has been moved to its new place." |
| 83 | + echo |
| 84 | +fi |
| 85 | +/sbin/chkconfig --del firehol |
| 86 | + |
| 87 | +%preun |
| 88 | +/sbin/chkconfig --del firehol |
| 89 | + |
| 90 | +%postun |
| 91 | + |
| 92 | +%clean |
| 93 | +rm -rf ${RPM_BUILD_DIR}/%{name}-%{version} |
| 94 | + |
| 95 | +%files |
| 96 | +%defattr(-,root,root) |
| 97 | +%doc README TODO COPYING ChangeLog WhatIsNew |
| 98 | + |
| 99 | +%dir /etc/firehol |
| 100 | +%dir /etc/firehol/examples |
| 101 | +%dir /etc/firehol/services |
| 102 | + |
| 103 | +/etc/init.d/firehol |
| 104 | +%{_mandir}/man1/firehol.1.gz |
| 105 | +%{_mandir}/man5/firehol.conf.5.gz |
| 106 | + |
| 107 | +%config(noreplace) /etc/firehol/firehol.conf |
| 108 | + |
| 109 | +/etc/firehol/examples/home-adsl.conf |
| 110 | +/etc/firehol/examples/home-dialup.conf |
| 111 | +/etc/firehol/examples/office.conf |
| 112 | +/etc/firehol/examples/server-dmz.conf |
| 113 | +/etc/firehol/examples/client-all.conf |
| 114 | +/etc/firehol/examples/lan-gateway.conf |
| 115 | + |
| 116 | +%doc adblock.sh get-iana.sh check-iana.sh |
| 117 | +%doc doc/adding.html |
| 118 | +%doc doc/css.css |
| 119 | +%doc doc/fwtest.html |
| 120 | +%doc doc/index.html |
| 121 | +%doc doc/language.html |
| 122 | +%doc doc/services.html |
| 123 | +%doc doc/search.html |
| 124 | +%doc doc/tutorial.html |
| 125 | +%doc doc/commands.html |
| 126 | +%doc doc/header.html |
| 127 | +%doc doc/invoking.html |
| 128 | +%doc doc/overview.html |
| 129 | +%doc doc/trouble.html |
| 130 | +%doc doc/faq.html |
| 131 | + |
| 132 | +%changelog |
0 commit comments