def exportXMLRules(self, parent): empty = self.default_decisions.exportXML(parent) empty &= Rules.exportXMLRules(self, parent) return empty
def __init__(self, ruleset, default_decisions, xml_tag): Rules.__init__(self, ruleset, xml_tag) self.default_decisions = default_decisions
def importXMLRules(self, rules, context, action): self.default_decisions.importXML(rules) Rules.importXMLRules(self, rules, context, action)
def __init__(self, ruleset): Rules.__init__(self, ruleset, "nats") self.chains = { u'PREROUTING': Chain(u'PREROUTING'), u'POSTROUTING' : Chain(u'POSTROUTING')}