From: Fede Date: Sat, 6 Oct 2007 16:01:30 +0000 (-0300) Subject: Bugfixes to firewall service. X-Git-Url: https://git.llucax.com/software/pymin.git/commitdiff_plain/3f2159307fa789f3af08c2bb129ff43ba87c80d2 Bugfixes to firewall service. --- diff --git a/pymin/services/firewall/__init__.py b/pymin/services/firewall/__init__.py index 229cc20..d14f3a6 100644 --- a/pymin/services/firewall/__init__.py +++ b/pymin/services/firewall/__init__.py @@ -112,7 +112,7 @@ class Rule(Sequence): def as_tuple(self): r"Return a tuple representing the rule." return (self.chain, self.target, self.src, self.dst, self.protocol, - self.src_port) + self.src_port, self.dst_port) class RuleHandler(Handler): r"""RuleHandler(rules) -> RuleHandler instance :: Handle a list of rules. @@ -197,8 +197,8 @@ class FirewallHandler(Restorable, ConfigWriter, ServiceHandler, r"Initialize the object, see class documentation for details." self._persistent_dir = pickle_dir self._config_writer_cfg_dir = config_dir - self._service_start = path.join(self._config_writer_cfg_dir, - self._config_writer_files) + self._service_start = ('sh', path.join(self._config_writer_cfg_dir, + self._config_writer_files)) self._service_stop = ('iptables', '-t', 'filter', '-F') self._service_restart = self._service_start self._service_reload = self._service_start