--- loncom/configuration/Firewall.pm 2021/12/20 03:13:29 1.23 +++ loncom/configuration/Firewall.pm 2021/12/21 13:57:47 1.24 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Firewall configuration to allow internal LON-CAPA communication between servers # -# $Id: Firewall.pm,v 1.23 2021/12/20 03:13:29 raeburn Exp $ +# $Id: Firewall.pm,v 1.24 2021/12/21 13:57:47 raeburn Exp $ # # The LearningOnline Network with CAPA # @@ -655,7 +655,7 @@ sub get_fw_chains { my $ubuntu_config = "/etc/ufw/ufw.conf"; my $firewalld = &uses_firewalld($distro); if ($firewalld) { - my ($dist,$version) = ($distro =~ /^([\D]+)(\d+)$/); + my ($dist,$version) = ($distro =~ /^([\D]+)(\d+)(?:|\-stream)$/); if (((($dist eq 'rhes') || ($dist eq 'centos') || ($dist eq 'rocky') || ($dist eq 'alma')) && ($version >= 8)) || (($dist eq 'oracle') && ($version >= 7))) { push(@fw_chains,'INPUT'); @@ -676,7 +676,7 @@ sub get_fw_chains { } else { if ($distro =~ /^(debian|ubuntu|suse|sles)/) { @posschains = ('INPUT'); - } elsif ($distro =~ /^(fedora|rhes|centos|scientific|oracle|rocky|alma)(\d+)$/) { + } elsif ($distro =~ /^(fedora|rhes|centos|scientific|oracle|rocky|alma)(\d+)(?:|\-stream)$/) { if ((($1 eq 'fedora') && ($2 > 15)) || (($1 ne 'fedora') && ($2 >= 7))) { @posschains = ('INPUT'); } else { @@ -689,7 +689,7 @@ sub get_fw_chains { print("Unable to find iptables file containing static definitions.\n"); } } - if ($distro =~ /^(fedora|rhes|centos|scientific|oracle|rocky|alma)(\d+)$/) { + if ($distro =~ /^(fedora|rhes|centos|scientific|oracle|rocky|alma)(\d+){?:|\-stream)$/) { unless ((($1 eq 'fedora') && ($2 > 15)) || (($1 ne 'fedora') && ($2 >= 7))) { push(@fw_chains,'RH-Firewall-1-INPUT'); }