Date: Saturday, January 30, 2016 @ 09:56:10 Author: alucryd Revision: 159476
upgpkg: firewalld 0.4.0-1 Added: firewalld/trunk/firewalld-arch.patch Modified: firewalld/trunk/PKGBUILD Deleted: firewalld/trunk/firewalld-fs46429.patch firewalld/trunk/firewalld-paths.patch -------------------------+ PKGBUILD | 40 ++++++++------ firewalld-arch.patch | 130 ++++++++++++++++++++++++++++++++++++++++++++++ firewalld-fs46429.patch | 62 --------------------- firewalld-paths.patch | 117 ----------------------------------------- 4 files changed, 153 insertions(+), 196 deletions(-) Modified: PKGBUILD =================================================================== --- PKGBUILD 2016-01-30 08:43:02 UTC (rev 159475) +++ PKGBUILD 2016-01-30 08:56:10 UTC (rev 159476) @@ -4,15 +4,16 @@ # Contributor: speed145a <jonat...@tagchapter.com> pkgname=firewalld -pkgver=0.3.14.2 -pkgrel=3 -pkgdesc='A dynamic firewall daemon with a D-BUS interface' +pkgver=0.4.0 +pkgrel=1 +pkgdesc='Firewall daemon with D-Bus interface' arch=('any') -url='http://fedorahosted.org/firewalld' +url='https://github.com/t-woerner/firewalld' license=('GPL2') -depends=('dbus-glib' 'ebtables' 'iptables' 'python-slip') -makedepends=('intltool' 'docbook-xsl') -optdepends=('gtk3: firewall-config' +depends=('dbus-glib' 'ebtables' 'ipset' 'iptables' 'python-slip') +makedepends=('docbook-xsl' 'intltool') +optdepends=('bash-completion: bash completion' + 'gtk3: firewall-config' 'libnm-glib: firewall-config and firewall-applet' 'libnotify: firewall-applet' 'python-pyqt4: firewall-applet') @@ -19,18 +20,17 @@ backup=('etc/conf.d/firewalld' 'etc/firewalld/firewalld.conf') install='firewalld.install' -source=("https://fedorahosted.org/released/firewalld/firewalld-${pkgver}.tar.bz2" - 'firewalld-paths.patch' - 'firewalld-fs46429.patch') -sha256sums=('4b6c3e1deab41b6002b8dc25639e466085941c98a6c14a56bef4f621a5651567' - '41591c5358c5ad8d43b29d72f42c331fcfc25e3d38c0ba5b3c818fc757ceef2f' - 'be0a7fa459f0f99e1fb1ded9fb1f61866f2718c55d9eb7bd3b163134ada03136') +source=("firewalld-${pkgver}.tar.gz::https://github.com/t-woerner/firewalld/archive/v${pkgver}.tar.gz" + 'firewalld-arch.patch') +sha256sums=('97f13b9fe28d7be7726ecc7d09a2ec85d47efade9859d0d0e37f426bc142f64b' + '0e10b2dd4eb2b3ca436c9539c9cdd5e612c0f150f51f5c7d50743700437a2bee') prepare() { cd firewalld-${pkgver} - patch -Np1 -i ../firewalld-paths.patch - patch -Np1 -i ../firewalld-fs46429.patch + patch -Np1 -i ../firewalld-arch.patch + + ./autogen.sh } build() { @@ -37,10 +37,17 @@ cd firewalld-${pkgver} ./configure \ - --prefix='/usr'\ + --prefix='/usr' \ --localstatedir='/var' \ --sbindir='/usr/bin' \ --sysconfdir='/etc' \ + --with-iptables='/usr/bin/iptables' \ + --with-iptables-restore='/usr/bin/iptables-restore' \ + --with-ip6tables='/usr/bin/ip6tables' \ + --with-ip6tables-restore='/usr/bin/ip6tables-restore' \ + --with-ebtables='/usr/bin/ebtables' \ + --with-ebtables-restore='/usr/bin/ebtables-restore' \ + --with-ipset='/usr/bin/ipset' \ --disable-schemas-compile make } @@ -49,7 +56,6 @@ cd firewalld-${pkgver} make DESTDIR="${pkgdir}" install - #chmod 755 "${pkgdir}"/usr/bin/firewall-applet } # vim: ts=2 sw=2 et: Added: firewalld-arch.patch =================================================================== --- firewalld-arch.patch (rev 0) +++ firewalld-arch.patch 2016-01-30 08:56:10 UTC (rev 159476) @@ -0,0 +1,130 @@ +diff -rupN firewalld.orig/config/firewalld.service.in firewalld/config/firewalld.service.in +--- firewalld.orig/config/firewalld.service.in 2014-02-27 09:22:50.519837109 +0100 ++++ firewalld/config/firewalld.service.in 2014-02-27 09:26:47.452013636 +0100 +@@ -6,7 +6,7 @@ Before=NetworkManager.service + Conflicts=iptables.service ip6tables.service ebtables.service + + [Service] +-EnvironmentFile=-/etc/sysconfig/firewalld ++EnvironmentFile=-/etc/conf.d/firewalld + ExecStart=@sbindir@/firewalld --nofork --nopid $FIREWALLD_ARGS + ExecReload=/bin/kill -HUP $MAINPID + # supress to log debug and error output also to /var/log/messages +diff -rupN firewalld.orig/config/Makefile.am firewalld/config/Makefile.am +--- firewalld.orig/config/Makefile.am 2014-02-27 09:22:50.519837109 +0100 ++++ firewalld/config/Makefile.am 2014-02-27 09:25:25.875010521 +0100 +@@ -143,12 +143,12 @@ firewalld.service: firewalld.service.in + $(edit) $< >$@ + + install-sysconfig: +- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/sysconfig +- $(INSTALL_DATA) $(srcdir)/firewalld.sysconfig $(DESTDIR)$(sysconfdir)/sysconfig/firewalld ++ $(MKDIR_P) $(DESTDIR)$(sysconfdir)/conf.d ++ $(INSTALL_DATA) $(srcdir)/firewalld.sysconfig $(DESTDIR)$(sysconfdir)/conf.d/firewalld + + uninstall-sysconfig: +- rm -f $(DESTDIR)$(sysconfdir)/sysconfig/firewalld +- rmdir $(DESTDIR)$(sysconfdir)/sysconfig || : ++ rm -f $(DESTDIR)$(sysconfdir)/conf.d/firewalld ++ rmdir $(DESTDIR)$(sysconfdir)/conf.d || : + + install-init: install-sysconfig + $(MKDIR_P) $(DESTDIR)$(sysconfdir)/rc.d/init.d +diff -rupN firewalld.orig/firewalld.spec firewalld/firewalld.spec +--- firewalld.orig/firewalld.spec 2014-02-27 09:22:50.596501411 +0100 ++++ firewalld/firewalld.spec 2014-02-27 09:32:37.082641586 +0100 +@@ -128,7 +128,7 @@ fi + %attr(0750,root,root) %dir %{_sysconfdir}/firewalld/services + %attr(0750,root,root) %dir %{_sysconfdir}/firewalld/zones + %defattr(0644,root,root) +-%config(noreplace) %{_sysconfdir}/sysconfig/firewalld ++%config(noreplace) %{_sysconfdir}/conf.d/firewalld + #%attr(0755,root,root) %{_initrddir}/firewalld + %{_unitdir}/firewalld.service + %config(noreplace) %{_sysconfdir}/dbus-1/system.d/FirewallD.conf +diff -rupN firewalld.orig/src/firewall-offline-cmd firewalld/src/firewall-offline-cmd +--- firewalld.orig/src/firewall-offline-cmd 2014-02-27 09:22:50.616500794 +0100 ++++ firewalld/src/firewall-offline-cmd 2014-02-27 09:28:41.451288466 +0100 +@@ -44,7 +44,7 @@ def __usage(): + print (""" + Usage: firewall-offline-cmd [OPTIONS...] + +-If no options are given, configuration from '/etc/sysconfig/system-config-firewall' will be migrated. ++If no options are given, configuration from '/etc/conf.d/system-config-firewall' will be migrated. + + General Options + -h, --help Prints a short help text and exists +@@ -70,7 +70,7 @@ Lokkit Compatibility Options + --custom-rules=[<type>:][<table>:]<filename> + Ignored option. Was used to add custom rules to the + firewall (Example: +- ipv4:filter:/etc/sysconfig/ipv4_filter_addon) ++ ipv4:filter:/etc/conf.d/ipv4_filter_addon) + --forward-port=if=<interface>:port=<port>:proto=<protocol>[:toport=<destination port>][:toaddr=<destination address>] + Forward the port with protocol for the interface to + either another local destination port (no destination +@@ -360,7 +360,7 @@ def __print_query_result(value): + __print_and_exit("no", 1) + + # system-config-firewall: fw_sysconfig +-CONFIG = '/etc/sysconfig/system-config-firewall' ++CONFIG = '/etc/conf.d/system-config-firewall' + def read_sysconfig_args(): + filename = None + if os.path.exists(CONFIG) and os.path.isfile(CONFIG): +@@ -523,7 +523,7 @@ parser_direct.add_argument("--get-all-ru + if len(sys.argv) > 1: + a = parser.parse_args() + else: +- # migrate configuration from /etc/sysconfig/system-config-firewall ++ # migrate configuration from /etc/conf.d/system-config-firewall + args = read_sysconfig_args() + if args: + a = parser.parse_args(args) +diff -rupN firewalld.orig/src/tests/firewall-offline-cmd_test.sh firewalld/src/tests/firewall-offline-cmd_test.sh +--- firewalld.orig/src/tests/firewall-offline-cmd_test.sh 2014-02-27 09:22:50.676498942 +0100 ++++ firewalld/src/tests/firewall-offline-cmd_test.sh 2014-02-27 09:33:49.063368985 +0100 +@@ -162,7 +162,7 @@ assert_good "--query-forward-port ${ + failures=0 + + while true; do +- read -p "This test overwrites your /etc/firewalld/zones/* and /etc/sysconfig/system-config-firewall. Do you want to continue ?" yn ++ read -p "This test overwrites your /etc/firewalld/zones/* and /etc/conf.d/system-config-firewall. Do you want to continue ?" yn + case $yn in + [Yy]* ) break;; + [Nn]* ) exit;; +@@ -187,14 +187,14 @@ fw_port2="port=333:proto=udp:toport=444" + lokkit_opts="--enabled --addmodule=abc --addmodule=efg --removemodule=xyz + --trust=${trusted_iface1} --trust=${trusted_iface2} + --masq=tun+ --masq=tap+ --port=7:tcp --port=666:udp +- --custom-rules=ipv4:mangle:/etc/sysconfig/ebtables-config ++ --custom-rules=ipv4:mangle:/etc/conf.d/ebtables-config + --service=${service1} --service=${service2} --remove-service=${service3} + --block-icmp=${icmp1} --block-icmp=${icmp2} + --forward-port=if=ippp+:${fw_port1} + --forward-port=if=ippp+:${fw_port2}" + test_lokkit_opts + +-cat << EOF > /etc/sysconfig/system-config-firewall ++cat << EOF > /etc/conf.d/system-config-firewall + --enabled + --addmodule=abc + --addmodule=efg +@@ -205,7 +205,7 @@ cat << EOF > /etc/sysconfig/system-confi + --masq=tap+ + --port=7:tcp + --port=666:udp +---custom-rules=ipv4:mangle:/etc/sysconfig/ebtables-config ++--custom-rules=ipv4:mangle:/etc/conf.d/ebtables-config + --service=${service1} + --service=${service2} + --remove-service=${service3} +@@ -215,7 +215,7 @@ cat << EOF > /etc/sysconfig/system-confi + --forward-port=if=ippp+:${fw_port2} + EOF + +-# running firewall-offline-cmd without options should import /etc/sysconfig/system-config-firewall ++# running firewall-offline-cmd without options should import /etc/conf.d/system-config-firewall + lokkit_opts="" + test_lokkit_opts + Deleted: firewalld-fs46429.patch =================================================================== --- firewalld-fs46429.patch 2016-01-30 08:43:02 UTC (rev 159475) +++ firewalld-fs46429.patch 2016-01-30 08:56:10 UTC (rev 159476) @@ -1,62 +0,0 @@ -From 3a1f22c95bb5723456533de5aa821143682b8e3d Mon Sep 17 00:00:00 2001 -From: Thomas Woerner <twoer...@redhat.com> -Date: Thu, 18 Jun 2015 16:55:40 +0200 -Subject: [PATCH] firewalld: Fixed 'pid_file' referenced before assignment - (RHBZ#1233232) - ---- - src/firewalld | 10 +++++----- - 1 file changed, 5 insertions(+), 5 deletions(-) - -diff --git a/src/firewalld b/src/firewalld -index 2db71a8..bd81316 100755 ---- a/src/firewalld -+++ b/src/firewalld -@@ -82,6 +82,7 @@ def setup_logging(args): - log.addDebugLogging("*", log.stdout) - - def startup(args): -+ pid_file = "/var/run/firewalld.pid" - try: - if not args.nofork: - # do the UNIX double-fork magic, see Stevens' "Advanced -@@ -119,7 +120,6 @@ def startup(args): - - if not args.nopid: - # write the pid file -- pid_file = "/var/run/firewalld.pid" - with open(pid_file, "w") as f: - f.write(str(os.getpid())) - -@@ -128,27 +128,27 @@ def startup(args): - server.run_server(args.debug_gc) - - # Clean up on exit -- if os.path.exists(pid_file) and not args.nopid: -+ if not args.nopid and os.path.exists(pid_file): - os.remove(pid_file) - - except OSError as e: - log.fatal(_("Fork #1 failed: %d (%s)") % (e.errno, e.strerror)) - log.error(traceback.format_exc()) -- if os.path.exists(pid_file) and not args.nopid: -+ if not args.nopid and os.path.exists(pid_file): - os.remove(pid_file) - sys.exit(1) - - except dbus.exceptions.DBusException as e: - log.fatal(str(e)) - log.error(traceback.format_exc()) -- if os.path.exists(pid_file) and not args.nopid: -+ if not args.nopid and os.path.exists(pid_file): - os.remove(pid_file) - sys.exit(1) - - except IOError as e: - log.fatal(str(e)) - log.error(traceback.format_exc()) -- if os.path.exists(pid_file) and not args.nopid: -+ if not args.nopid and os.path.exists(pid_file): - os.remove(pid_file) - sys.exit(1) - Deleted: firewalld-paths.patch =================================================================== --- firewalld-paths.patch 2016-01-30 08:43:02 UTC (rev 159475) +++ firewalld-paths.patch 2016-01-30 08:56:10 UTC (rev 159476) @@ -1,117 +0,0 @@ -diff -rupN firewalld-0.3.10.orig/config/firewalld.service.in firewalld-0.3.10/config/firewalld.service.in ---- firewalld-0.3.10.orig/config/firewalld.service.in 2014-06-10 11:07:27.864758482 +0200 -+++ firewalld-0.3.10/config/firewalld.service.in 2014-06-10 11:07:39.582420959 +0200 -@@ -6,7 +6,7 @@ Before=NetworkManager.service - Conflicts=iptables.service ip6tables.service ebtables.service - - [Service] --EnvironmentFile=-/etc/sysconfig/firewalld -+EnvironmentFile=-/etc/conf.d/firewalld - ExecStart=@sbindir@/firewalld --nofork --nopid $FIREWALLD_ARGS - ExecReload=/bin/kill -HUP $MAINPID - # supress to log debug and error output also to /var/log/messages -diff -rupN firewalld-0.3.10.orig/config/Makefile.am firewalld-0.3.10/config/Makefile.am ---- firewalld-0.3.10.orig/config/Makefile.am 2014-06-10 11:07:27.851758856 +0200 -+++ firewalld-0.3.10/config/Makefile.am 2014-06-10 11:07:39.580421016 +0200 -@@ -164,12 +164,12 @@ firewalld.service: firewalld.service.in - $(edit) $< >$@ - - install-sysconfig: -- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/sysconfig -- $(INSTALL_DATA) $(srcdir)/firewalld.sysconfig $(DESTDIR)$(sysconfdir)/sysconfig/firewalld -+ $(MKDIR_P) $(DESTDIR)$(sysconfdir)/conf.d -+ $(INSTALL_DATA) $(srcdir)/firewalld.sysconfig $(DESTDIR)$(sysconfdir)/conf.d/firewalld - - uninstall-sysconfig: -- rm -f $(DESTDIR)$(sysconfdir)/sysconfig/firewalld -- rmdir $(DESTDIR)$(sysconfdir)/sysconfig || : -+ rm -f $(DESTDIR)$(sysconfdir)/conf.d/firewalld -+ rmdir $(DESTDIR)$(sysconfdir)/conf.d || : - - install-init: install-sysconfig - $(MKDIR_P) $(DESTDIR)$(sysconfdir)/rc.d/init.d -diff -rupN firewalld-0.3.10.orig/config/Makefile.in firewalld-0.3.10/config/Makefile.in ---- firewalld-0.3.10.orig/config/Makefile.in 2014-06-10 11:07:27.782760844 +0200 -+++ firewalld-0.3.10/config/Makefile.in 2014-06-10 11:07:39.581420988 +0200 -@@ -761,12 +761,12 @@ firewalld.service: firewalld.service.in - $(edit) $< >$@ - - install-sysconfig: -- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/sysconfig -- $(INSTALL_DATA) $(srcdir)/firewalld.sysconfig $(DESTDIR)$(sysconfdir)/sysconfig/firewalld -+ $(MKDIR_P) $(DESTDIR)$(sysconfdir)/conf.d -+ $(INSTALL_DATA) $(srcdir)/firewalld.sysconfig $(DESTDIR)$(sysconfdir)/conf.d/firewalld - - uninstall-sysconfig: -- rm -f $(DESTDIR)$(sysconfdir)/sysconfig/firewalld -- rmdir $(DESTDIR)$(sysconfdir)/sysconfig || : -+ rm -f $(DESTDIR)$(sysconfdir)/conf.d/firewalld -+ rmdir $(DESTDIR)$(sysconfdir)/conf.d || : - - install-init: install-sysconfig - $(MKDIR_P) $(DESTDIR)$(sysconfdir)/rc.d/init.d -diff -rupN firewalld-0.3.10.orig/src/firewall/core/ebtables.py firewalld-0.3.10/src/firewall/core/ebtables.py ---- firewalld-0.3.10.orig/src/firewall/core/ebtables.py 2014-06-10 11:07:27.340773575 +0200 -+++ firewalld-0.3.10/src/firewall/core/ebtables.py 2014-06-10 11:07:39.585420873 +0200 -@@ -37,7 +37,7 @@ class ebtables: - ipv = "ipv4" - - def __init__(self): -- self._command = "/sbin/ebtables" -+ self._command = "/usr/bin/ebtables" - - def __run(self, args): - # convert to string list -diff -rupN firewalld-0.3.10.orig/src/firewall/core/ipXtables.py firewalld-0.3.10/src/firewall/core/ipXtables.py ---- firewalld-0.3.10.orig/src/firewall/core/ipXtables.py 2014-06-10 11:07:27.340773575 +0200 -+++ firewalld-0.3.10/src/firewall/core/ipXtables.py 2014-06-10 11:07:39.586420844 +0200 -@@ -25,8 +25,8 @@ from firewall.core.prog import runProg - from firewall.core.logger import log - - COMMAND = { -- "ipv4": "/sbin/iptables", -- "ipv6": "/sbin/ip6tables", -+ "ipv4": "/usr/bin/iptables", -+ "ipv6": "/usr/bin/ip6tables", - } - - PROC_IPxTABLE_NAMES = { -diff -rupN firewalld-0.3.10.orig/src/firewall-offline-cmd firewalld-0.3.10/src/firewall-offline-cmd ---- firewalld-0.3.10.orig/src/firewall-offline-cmd 2014-06-10 11:07:27.339773604 +0200 -+++ firewalld-0.3.10/src/firewall-offline-cmd 2014-06-10 11:09:17.747594086 +0200 -@@ -44,7 +44,7 @@ def __usage(): - print (""" - Usage: firewall-offline-cmd [OPTIONS...] - --If no options are given, configuration from '/etc/sysconfig/system-config-firewall' will be migrated. -+If no options are given, configuration from '/etc/conf.d/system-config-firewall' will be migrated. - - General Options - -h, --help Prints a short help text and exists -@@ -70,7 +70,7 @@ Lokkit Compatibility Options - --custom-rules=[<type>:][<table>:]<filename> - Ignored option. Was used to add custom rules to the - firewall (Example: -- ipv4:filter:/etc/sysconfig/ipv4_filter_addon) -+ ipv4:filter:/etc/conf.d/ipv4_filter_addon) - --forward-port=if=<interface>:port=<port>:proto=<protocol>[:toport=<destination port>][:toaddr=<destination address>] - Forward the port with protocol for the interface to - either another local destination port (no destination -@@ -376,7 +376,7 @@ def __pk_symlink(product='server'): - __fail('no such file '+_PK_DIR+_PK_NAME+product+'.policy') - - # system-config-firewall: fw_sysconfig --CONFIG = '/etc/sysconfig/system-config-firewall' -+CONFIG = '/etc/conf.d/system-config-firewall' - def read_sysconfig_args(): - filename = None - if os.path.exists(CONFIG) and os.path.isfile(CONFIG): -@@ -562,7 +562,7 @@ if len(sys.argv) > 1: - args.append(joinArgs(aux_args[i+1:])) # add <args> as one arg - a = parser.parse_args(args) - else: -- # migrate configuration from /etc/sysconfig/system-config-firewall -+ # migrate configuration from /etc/conf.d/system-config-firewall - args = read_sysconfig_args() - if args: - a = parser.parse_args(args)