当前位置: 首页>>代码示例>>Python>>正文


Python Analyzer.__init__方法代码示例

本文整理汇总了Python中cortexutils.analyzer.Analyzer.__init__方法的典型用法代码示例。如果您正苦于以下问题:Python Analyzer.__init__方法的具体用法?Python Analyzer.__init__怎么用?Python Analyzer.__init__使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在cortexutils.analyzer.Analyzer的用法示例。


在下文中一共展示了Analyzer.__init__方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
 def __init__(self):
     Analyzer.__init__(self)
     self.service = self.get_param(
         'config.service', None, 'Service parameter is missing')
     self.key = self.get_param('config.key', None, 'Missing API key')
     self.pwd = self.get_param('config.pwd', None, 'Missing API password')
     self.request_handler = APIRequestHandler(self.key, self.pwd)
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:9,代码来源:fireeyeisight_lookup.py

示例2: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
    def __init__(self):
        Analyzer.__init__(self)
        self.service = self.get_param(
            "config.service", None, "SecurityTrails service is missing")

        self.api_key = self.get_param(
            "config.api_key", None, "SecurityTrails API key is missing")
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:9,代码来源:securitytrails_analyzer.py

示例3: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
    def __init__(self):
        Analyzer.__init__(self)
        self.basic_url = 'https://www.hybrid-analysis.com/api/'
        self.headers = {'User-Agent': 'VxStream'}

        self.secret = self.get_param('config.secret', None, 'VxStream Sandbox secret key is missing')
        self.api_key = self.get_param('config.key', None, 'VxStream Sandbox API key is missing')
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:9,代码来源:HybridAnalysis_analyzer.py

示例4: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
    def __init__(self):
        Analyzer.__init__(self)

        # Fixes #94. Instead of None, the string Unnamed should be passed to MISPClient constructor
        name = self.get_param('config.name', None)
        if not name or len(name) == 0:
            name = 'Unnamed'
        if self.get_param('config.cert_check', True):
            ssl_path = self.get_param('config.cert_path', None)
            if not ssl_path or ssl_path == '':
                ssl = True
            else:
                ssl = ssl_path
        else:
            ssl = False
        try:
            self.misp = MISPClient(url=self.get_param('config.url', None, 'No MISP url given.'),
                                   key=self.get_param('config.key', None, 'No MISP api key given.'),
                                   ssl=ssl,
                                   name=name,
                                   proxies={'http': self.http_proxy, 'https': self.https_proxy})
        except MISPClientError as e:
            self.error(str(e))
        except TypeError as te:
            self.error(str(te))
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:27,代码来源:misp.py

示例5: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
 def __init__(self):
     Analyzer.__init__(self)
     self.service = self.get_param('config.service', None, 'Service parameter is missing')
     self.api_key = self.get_param('config.api_key', None, 'api_key is missing')
     self.api_secret = self.get_param('config.api_secret', None, 'api_secret is missing')
     self.organization_id = self.get_param('config.organization_id', None, 'organization_id is missing')
     self.query_limit = str(self.get_param('config.query_limit', None, 20))
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:9,代码来源:Umbrella.py

示例6: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
    def __init__(self):
        Analyzer.__init__(self)
        self.filepath = self.get_param('file', None, 'File parameter is missing.')
        self.filename = self.get_param('filename', None, 'Filename is missing.')
        self.filetype = pyexifinfo.fileType(self.filepath)
        self.mimetype = magic.Magic(mime=True).from_file(self.filepath)

        # Check if manalyze submodule is enabled
        if self.get_param('config.manalyze_enable', False, 'Parameter manalyze_enable not given.'
                                                           'Please enable or disable manalyze submodule explicitly.'):
            binary_path = self.get_param('config.manalyze_binary_path',
                                         '/opt/Cortex-Analyzers/utils/manalyze/bin/manalyze')
            if self.get_param('config.manalyze_enable_docker', False):
                available_submodules.append(
                    ManalyzeSubmodule(
                        use_docker=True
                    )
                )
            elif self.get_param('config.manalyze_enable_binary', False) \
                    and os.path.isfile(binary_path):
                available_submodules.append(
                    ManalyzeSubmodule(
                        use_binary=True,
                        binary_path=binary_path
                    )
                )
            else:
                self.error('Manalyze submodule is enabled, but either there is no method allowed (docker or binary)'
                           'or the path to binary is not correct.')
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:31,代码来源:fileinfo_analyzer.py

示例7: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
 def __init__(self):
     Analyzer.__init__(self)
     self.service = self.get_param('config.service', None, 'Service parameter is missing')
     self.virustotal_key = self.get_param('config.key', None, 'Missing VirusTotal API key')
     self.polling_interval = self.get_param('config.polling_interval', 60)
     self.proxies = self.get_param('config.proxy', None)
     self.vt = VirusTotalPublicApi(self.virustotal_key, self.proxies)
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:9,代码来源:virustotal.py

示例8: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
 def __init__(self):
     Analyzer.__init__(self)
     self.service = self.get_param(
         'config.service', None, 'Service parameter is missing')
     self.url = self.get_param('config.url', None, 'Missing API url')
     self.key = self.get_param('config.key', None, 'Missing API key')
     self.pwd = self.get_param('config.pwd', None, 'Missing API password')
开发者ID:scrublullz,项目名称:Cortex-Analyzers,代码行数:9,代码来源:ibmxforce_lookup.py

示例9: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
    def __init__(self):
        Analyzer.__init__(self)

        self.data = self.get_data()
        self.path = self.get_param('config.path', 'misp-warninglists')
        if not exists(self.path):
            self.error('Path to misp-warninglists does not exist.')
        self.warninglists = self.readwarninglists()
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:10,代码来源:mispwarninglists.py

示例10: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
 def __init__(self):
     Analyzer.__init__(self)
     self.service = self.get_param(
         'config.service', None, 'Service parameter is missing')
     self.dnsdb_server = self.get_param(
         'config.server', None, 'Missing DNSDB server name')
     self.dnsdb_key = self.get_param(
         'config.key', None, 'Missing DNSDB API key')
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:10,代码来源:dnsdb.py

示例11: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
    def __init__(self):
        Analyzer.__init__(self)

        #filename of the observable
        self.filename = self.getParam('attachment.name', 'noname.ext')

        #filepath to the observable, looks like /tmp/cortex-4224850437865873235-datafile
        self.filepath = self.getParam('file', None, 'File is missing')
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:10,代码来源:parse.py

示例12: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
    def __init__(self):

        Analyzer.__init__(self)

        self.service = self.getParam('config.service', None,
                                     'Cymon service is missing')
        self.key = self.getParam('config.key', None,
                                 'Cymon API key is missing')
        self.con = CymonEngine(self.key)
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:11,代码来源:cymon_analyzer.py

示例13: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
    def __init__(self):
        Analyzer.__init__(self)
        self.service = self.get_param('config.service', None, 'Service parameter is missing')

        if self.service == "status":
            self.url = 'https://api.hashdd.com/'
        elif self.service == "detail":
            self.hashdd_key = self.get_param('config.api_key', None, 'Missing hashdd API key')
            self.url = 'https://api.hashdd.com/detail'
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:11,代码来源:Hashdd.py

示例14: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
    def __init__(self):
        Analyzer.__init__(self)

        self.url = 'https://pulsedive.com/api/'
        self.key = self.get_param('config.key', None, 'API-Key not given.')
        self.mapping = {
            'high': 'malicious',
            'medium': 'suspicious',
            'low': 'info'
        }
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:12,代码来源:pulsedive.py

示例15: __init__

# 需要导入模块: from cortexutils.analyzer import Analyzer [as 别名]
# 或者: from cortexutils.analyzer.Analyzer import __init__ [as 别名]
 def __init__(self):
     Analyzer.__init__(self)
     self.service = self.get_param('config.service', None, 'JoeSandbox service is missing')
     self.url = self.get_param('config.url', None, 'JoeSandbox url is missing')
     if self.get_param('config.key'):
         self.apikey = self.get_param('config.key')
     else:
         self.apikey = self.get_param('config.apikey', None, 'JoeSandbox API key is missing')
     self.analysistimeout = self.get_param('config.analysistimeout', 30*60, None)
     self.networktimeout = self.get_param('config.networktimeout', 30, None)
开发者ID:Cyberprotect,项目名称:Cortex-Analyzers,代码行数:12,代码来源:joesandbox_analyzer.py


注:本文中的cortexutils.analyzer.Analyzer.__init__方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。