コード例 #1
0
ファイル: ids_ips.py プロジェクト: maximerobin/Ufwi
 def init(self, core):
     ConfigServiceComponent.init(self, core)
     self.addConfFile("/etc/snort_inline/edenwall-home-net.conf",
                      "root:root", "0644")
     try:
         self.handle_transition()
     except Exception, err:
         self.critical(
             "Could not handle configuration transition to new IDS-IPS backend (%s)."
             % exceptionAsUnicode(err))
コード例 #2
0
ファイル: syslog_export.py プロジェクト: maximerobin/Ufwi
 def init(self, core):
     ConfigServiceComponent.init(self, core)
     self.core = core
     try:
         self.sharedir = self.core.config.get('CORE', 'sharedir')
     except:
         self.sharedir = DEFAULT_SHAREDIR
     self.script_dir = os.path.join(self.sharedir, 'scripts')
     self.addConfFile(_ULOGD_CONF, 'root:root', '0644')
     self.addConfFile(_RSYSLOG_CONF, 'root:root', '0644')
コード例 #3
0
ファイル: snmpd.py プロジェクト: maximerobin/Ufwi
 def init(self, core):
     ConfigServiceComponent.init(self, core)
     self.core = core
     depend_key = ("contact", "admin_mail")
     depend_name = "contact_snmpd"
     for (event, method) in (
         ("modify", self.read_config),
         ("apply", self.apply_config),
         ("rollback", self.apply_config),
     ):
         self.core.config_manager.subscribe(method, depend_name, (), event, *depend_key)
     self.addConfFile("/etc/default/snmpd", "root:root", "0644")
     self.addConfFile("/etc/snmp/snmpd.conf", "root:root", "0644")
     self.snmp_users_filename = "/var/lib/snmp/snmpd.conf"
コード例 #4
0
ファイル: auth_cert.py プロジェクト: maximerobin/Ufwi
 def init(self, core):
     ConfigServiceComponent.init(self, core)
     UseCertificateComponent.init(self, core)
     self.core = core
     try:
         self.sharedir = self.core.config.get('CORE', 'sharedir')
     except:
         self.sharedir = DEFAULT_SHAREDIR
     self.script_dir = os.path.join(self.sharedir, 'scripts')
     self.addConfFile(_NUAUTH_CONF, 'root:root', '0644')
     self.addConfFile('/etc/nufw/nuauth.d/nuauth_tls.conf', 'root:root',
                      '0644')
     self.addConfFile('/etc/nufw/user-down.sh', 'root:root', '0755')
     self.addConfFile('/etc/nufw/user-up.sh', 'root:root', '0755')
コード例 #5
0
ファイル: bind.py プロジェクト: maximerobin/Ufwi
    def init(self, core):
        ConfigServiceComponent.init(self, core)

        depend_key = ('nuauth_bind', 'nuauth_bind_dependency')
        depend_name = 'nuauth_bind'

        for (event, method) in (
            ('modify', self.read_config),
            ('apply', self.apply_config),
            ('rollback', self.apply_config)
            ):
            self.core.config_manager.subscribe(method, depend_name, (),
                                               event, *depend_key)

        self.addConfFile('/etc/bind/named.conf', 'root:bind', '0644')
        self.addConfFile('/etc/bind/named.conf.local', 'root:bind', '0644')
        self.addConfFile('/etc/bind/named.conf.options', 'root:bind', '0644')
コード例 #6
0
ファイル: antivirus.py プロジェクト: maximerobin/Ufwi
 def init(self, core):
     ConfigServiceComponent.init(self, core)
コード例 #7
0
ファイル: hosts.py プロジェクト: maximerobin/Ufwi
 def init(self, core):
     ConfigServiceComponent.init(self, core)
     if not self.key_exists:
         self.useDefaultConf()
コード例 #8
0
ファイル: dhcp.py プロジェクト: maximerobin/Ufwi
 def init(self, core):
     ConfigServiceComponent.init(self, core)
     self.addConfFile('/etc/dhcp3/dhcpd.conf', 'root:root', '0644')
     self.addConfFile('/etc/ha.d/resource.d/omshell_dhcpd', 'root:root', '0755')
コード例 #9
0
ファイル: exim.py プロジェクト: maximerobin/Ufwi
 def init(self, core):
     ConfigServiceComponent.init(self, core)
     for genfile in GEN_FILES:
         self.addConfFile(genfile, 'root:root', '0644')
コード例 #10
0
ファイル: openvpn.py プロジェクト: maximerobin/Ufwi
 def init(self, core):
     UseCertificateComponent.init(self, core)
     self.context = Context.fromComponent(self)
     for filename in self.CONF_FILES:
         self.addConfFile(filename, 'root:root', '0644')
     ConfigServiceComponent.init(self, core)
コード例 #11
0
ファイル: hostname.py プロジェクト: maximerobin/Ufwi
 def init(self, core):
     ConfigServiceComponent.init(self, core)
     self.addConfFile('/etc/hostname', 'root:root', '0644')