check chain name length (max 28 chars)
[pve-firewall.git] / pvefw
diff --git a/pvefw b/pvefw
index 9ba332d..1c346b5 100755 (executable)
--- a/pvefw
+++ b/pvefw
@@ -82,7 +82,8 @@ __PACKAGE__->register_method ({
        my ($param) = @_;
 
        my $code = sub {
-           PVE::Firewall::compile_and_start($param->{verbose});
+           my $ruleset = PVE::Firewall::compile();
+           PVE::Firewall::apply_ruleset($ruleset, $param->{verbose});
        };
 
        PVE::Firewall::run_locked($code);
@@ -107,16 +108,16 @@ __PACKAGE__->register_method ({
        my $code = sub {
            my $chash = PVE::Firewall::iptables_get_chains();
            my $cmdlist = "*filter\n";
-           my $rule = "INPUT -j proxmoxfw-INPUT";
+           my $rule = "INPUT -j PVEFW-INPUT";
            if (PVE::Firewall::iptables_rule_exist($rule)) {
                $cmdlist .= "-D $rule\n";
            }
-           $rule = "OUTPUT -j proxmoxfw-OUTPUT";
+           $rule = "OUTPUT -j PVEFW-OUTPUT";
            if (PVE::Firewall::iptables_rule_exist($rule)) {
                $cmdlist .= "-D $rule\n";
            }
 
-           $rule = "FORWARD -j proxmoxfw-FORWARD";
+           $rule = "FORWARD -j PVEFW-FORWARD";
            if (PVE::Firewall::iptables_rule_exist($rule)) {
                $cmdlist .= "-D $rule\n";
            }