summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorGaurav <gaurav.sinha@vyatta.com>2012-02-22 10:30:52 -0800
committerGaurav Sinha <gaurav.sinha@vyatta.com>2012-03-16 16:41:45 -0700
commite02c2bf7724c050e348dba14fa964375ba92a37b (patch)
treedb4b40ee02ec7c2095d160e08646f6b78b197c32 /scripts
parent0f242d1a1fa363b19229b886622ef9ca3a4f50b5 (diff)
downloadvyatta-conntrack-e02c2bf7724c050e348dba14fa964375ba92a37b.tar.gz
vyatta-conntrack-e02c2bf7724c050e348dba14fa964375ba92a37b.zip
adding various timers in custom rule template
(cherry picked from commit ebae932dd450c23d90d1f9d497e2715af535577f)
Diffstat (limited to 'scripts')
-rw-r--r--scripts/vyatta-conntrack-timeouts.pl12
1 files changed, 3 insertions, 9 deletions
diff --git a/scripts/vyatta-conntrack-timeouts.pl b/scripts/vyatta-conntrack-timeouts.pl
index 7395b06..a079ed1 100644
--- a/scripts/vyatta-conntrack-timeouts.pl
+++ b/scripts/vyatta-conntrack-timeouts.pl
@@ -31,7 +31,6 @@ sub update_config {
$config->setLevel("system conntrack timeout custom rule");
%rules = $config->listNodeStatus();
- print %rules;
foreach my $rule (sort keys %rules) {
if ("$rules{$rule}" eq 'static') {
} elsif ("$rules{$rule}" eq 'added') {
@@ -39,15 +38,10 @@ sub update_config {
$node->setup("system conntrack timeout custom rule $rule");
$node->print();
} elsif ("$rules{$rule}" eq 'changed') {
+ my $node = new Vyatta::Conntrack::RuleCT;
+ $node->setup("system conntrack timeout custom rule $rule");
+ $node->print();
} elsif ("$rules{$rule}" eq 'deleted') {
-# my $node = new Vyatta::Conntrack::RuleCT;
-# $node->setupOrig("system conntrack timeout custom rule $rule");
-# my $ipt_rules = $node->get_num_ipt_rules();
-# for (1 .. $ipt_rules) {
-# print "deleting 1\n";
-# run_cmd("$iptables_cmd -t $table --delete $name $iptablesrule");
-# die "$iptables_cmd error: $! - $rule" if ($? >> 8);
-# }
}
}
}