How to use the pycti.OpenCTI function in pycti

To help you get started, we’ve selected a few pycti examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github OpenCTI-Platform / opencti / opencti-worker / worker_import.py View on Github external
def __init__(self, verbose=True):
        # Initialize logger
        self.logger = Logger(os.path.dirname(os.path.abspath(__file__)) + '/logs/worker.log')

        # Load configuration
        self.config = yaml.load(open(os.path.dirname(os.path.abspath(__file__)) + '/config.yml'))

        # Initialize OpenCTI client
        self.opencti = OpenCTI(
            self.config['opencti']['api_url'],
            self.config['opencti']['api_key'],
            os.path.dirname(os.path.abspath(__file__)) + '/logs/worker.log',
            self.config['opencti']['verbose']
        )
github OpenCTI-Platform / opencti / opencti-integration / connectors_scheduler.py View on Github external
def __init__(self, verbose=True):

        # Initialize connectors object
        self.connectors = {}

        # Initialize logger
        self.logger = Logger(os.path.dirname(os.path.abspath(__file__)) + '/scheduler.log')

        # Load configuration
        self.config = yaml.load(open(os.path.dirname(os.path.abspath(__file__)) + '/config.yml'))

        # Initialize OpenCTI client
        self.opencti = OpenCTI(
            self.config['opencti']['api_url'],
            self.config['opencti']['api_key'],
            os.path.dirname(os.path.abspath(__file__)) + '/scheduler.log',
            self.config['opencti']['verbose']
        )

pycti

Python API client for OpenCTI.

Apache-2.0
Latest version published 5 days ago

Package Health Score

72 / 100
Full package analysis

Popular pycti functions

Similar packages