--- /dev/null
+diff -ur shorewall-5.2.0.5.orig/shorewall-5.2.0.5/Perl/Shorewall/Chains.pm shorewall-5.2.0.5/shorewall-5.2.0.5/Perl/Shorewall/Chains.pm
+--- shorewall-5.2.0.5.orig/shorewall-5.2.0.5/Perl/Shorewall/Chains.pm 2018-08-05 17:31:09.000000000 +0000
++++ shorewall-5.2.0.5/shorewall-5.2.0.5/Perl/Shorewall/Chains.pm 2018-09-06 15:14:31.187972699 +0000
+@@ -5819,7 +5819,7 @@
+
+ $chain =~ s/[^\w-]//g;
+ # $1 $2 - $3
+- while ( $condition =~ m( ^(.*?) @({)?(?:0|chain)(?(2)}) (.*)$ )x ) {
++ while ( $condition =~ m( ^(.*?) @(\{)?(?:0|chain)(?(2)}) (.*)$ )x ) {
+ $condition = join( '', $1, $chain, $3 );
+ }
+
+diff -ur shorewall-5.2.0.5.orig/shorewall-5.2.0.5/Perl/Shorewall/Config.pm shorewall-5.2.0.5/shorewall-5.2.0.5/Perl/Shorewall/Config.pm
+--- shorewall-5.2.0.5.orig/shorewall-5.2.0.5/Perl/Shorewall/Config.pm 2018-08-05 17:31:09.000000000 +0000
++++ shorewall-5.2.0.5/shorewall-5.2.0.5/Perl/Shorewall/Config.pm 2018-09-06 15:14:25.806972759 +0000
+@@ -2833,7 +2833,7 @@
+ }
+
+ # $1 $2 $3 - $4
+- while ( $expression =~ m( ^(.*?) \$({)? (\d+|[a-zA-Z_]\w*) (?(2)}) (.*)$ )x ) {
++ while ( $expression =~ m( ^(.*?) \$(\{)? (\d+|[a-zA-Z_]\w*) (?(2)}) (.*)$ )x ) {
+ my ( $first, $var, $rest ) = ( $1, $3, $4);
+
+ if ( $var =~ /^\d+$/ ) {
+@@ -2850,7 +2850,7 @@
+
+ if ( $chain ) {
+ # $1 $2 $3 - $4
+- while ( $expression =~ m( ^(.*?) \@({)? (\d+|[a-zA-Z]\w*) (?(2)}) (.*)$ )x ) {
++ while ( $expression =~ m( ^(.*?) \@(\{)? (\d+|[a-zA-Z]\w*) (?(2)}) (.*)$ )x ) {
+ my ( $first, $var, $rest ) = ( $1, $3, $4);
+ $var = numeric_value( $var ) if $var =~ /^\d/;
+ $val = $var ? $actparams{$var} : $chain;
+@@ -2861,7 +2861,7 @@
+ }
+
+ # $1 $2 $3 - $4
+- while ( $expression =~ m( ^(.*?) __({)? (\w+) (?(2)}) (.*)$ )x ) {
++ while ( $expression =~ m( ^(.*?) __(\{)? (\w+) (?(2)}) (.*)$ )x ) {
+ my ( $first, $cap, $rest ) = ( $1, $3, $4);
+
+ if ( exists $capdesc{$cap} ) {
+@@ -3791,7 +3791,7 @@
+ my ( $lineref, $count ) = ( $_[0], 0 );
+ my $chain = $actparams{chain};
+ # $1 $2 $3 - $4
+- while ( $$lineref =~ m( ^(.*?) \$({)? (\d+|[a-zA-Z_]\w*) (?(2)}) (.*)$ )x ) {
++ while ( $$lineref =~ m( ^(.*?) \$(\{)? (\d+|[a-zA-Z_]\w*) (?(2)}) (.*)$ )x ) {
+
+ my ( $first, $var, $rest ) = ( $1, $3, $4);
+
+@@ -3830,7 +3830,7 @@
+ #
+ $$lineref =~ s/\\@/??/g;
+ # $1 $2 $3 - $4
+- while ( $$lineref =~ m( ^(.*?) \@({)? (\d+|[a-zA-Z_]\w*) (?(2)}) (.*)$ )x ) {
++ while ( $$lineref =~ m( ^(.*?) \@(\{)? (\d+|[a-zA-Z_]\w*) (?(2)}) (.*)$ )x ) {
+ my ( $first, $var, $rest ) = ( $1, $3, $4);
+ my $val = $var ? $actparams{$var} : $actparams{chain};
+ $usedcaller = USEDCALLER if $var eq 'caller';
+@@ -3846,7 +3846,7 @@
+ sub expand_shorewallrc_variables( \$ ) {
+ my ( $lineref, $count ) = ( $_[0], 0 );
+ # $1 $2 $3 - $4
+- while ( $$lineref =~ m( ^(.*?) \$({)? (\d+|[a-zA-Z]\w*) (?(2)}) (.*)$ )x ) {
++ while ( $$lineref =~ m( ^(.*?) \$(\{)? (\d+|[a-zA-Z]\w*) (?(2)}) (.*)$ )x ) {
+
+ my ( $first, $var, $rest ) = ( $1, $3, $4);
+
# NOTE:
# A very helpful document for packaging Shorewall is "Anatomy of Shorewall 4.0"
# which is found at http://www.shorewall.net/Anatomy.html
-# TODO
-# - rc-script inits
+#
Summary: Shoreline Firewall - an iptables-based firewall for Linux systems
Summary(pl.UTF-8): Shoreline Firewall - zapora sieciowa oparta na iptables
Name: shorewall
Version: 5.2.0.5
-Release: 1
+Release: 2
License: GPL
Group: Networking/Utilities
Source0: http://www.shorewall.net/pub/shorewall/5.2/shorewall-5.2.0/%{name}-%{version}.tar.bz2
Patch3: man.patch
Patch4: init.patch
Patch5: shell-fix.patch
+Patch6: perl.patch
URL: http://www.shorewall.net/
BuildRequires: perl
BuildRequires: perl(Digest::SHA)
%patch3 -p1
%patch4 -p1
%patch5 -p1
+%patch6 -p1
# Remove hash-bang from files which are not directly executed as shell
# scripts. This silences some rpmlint errors.