Skip to content

Cybereason Defense Platform Executor

Category: Endpoint Security Script: cybereason.py Integration: REST API (session login) Faraday Plugin: Raw JSON Website: https://www.cybereason.com/platform/defense-platform

Description

Imports Malops (detected malicious operations) and the sensor inventory from a Cybereason Defense Platform tenant, hosted or on-premises, into Faraday. Each sensor becomes a Faraday host, and each Malop becomes an [EDR] vulnerability on the machines it affects.

Prerequisites

  • A Cybereason Defense Platform tenant (hosted or on-premises) reachable from the agent
  • A Cybereason user with read access to Malops and sensors (for example, a dedicated analyst user)
  • The requests Python package in the agent environment

Configuration

Environment Variables (Setup)

Variable Required Description
CR_HOST Yes URL of your Cybereason console (e.g., https://acme.cybereason.net or https://defense.acme.corp:8443). https:// is added if you omit the scheme.
CR_USER Yes Cybereason username
CR_PASSWORD Yes Cybereason password
CR_VERIFY_SSL No Set to false to skip TLS certificate validation, for example for on-premises consoles with self-signed certificates (default: true)

CR_HOST, CR_USER and CR_PASSWORD are also accepted as execution arguments, so a single run can override them.

Execution Arguments

Parameter Type Mandatory Description
CR_MIN_SEVERITY string No Minimum severity to import: info, low, medium, high or critical (default: info)
CR_MALOP_TYPE string No Comma-separated Malop types to import, e.g. MalopProcess,MalopLogon (default: MalopProcess,MalopLogon,MalopFileless)
CR_INCLUDE_PROCESS_EVIDENCE boolean No Set to true to fetch the root-cause process evidence of each Malop and add it to the description. This adds one request per Malop (default: false).

YAML Configuration Example

executors:
  cybereason:
    repo_executor: cybereason.py
    max_size: 65536
    varenvs:
      CR_HOST: "https://acme.cybereason.net"
      CR_USER: "<username>"
      CR_PASSWORD: "<password>"
    params:
      CR_MIN_SEVERITY:
        mandatory: false
        type: string
        base: string
      CR_MALOP_TYPE:
        mandatory: false
        type: string
        base: string
      CR_INCLUDE_PROCESS_EVIDENCE:
        mandatory: false
        type: boolean
        base: string

How It Works

  1. Logs in with a form POST to {CR_HOST}/login.html and keeps the returned JSESSIONID session cookie
  2. Queries {CR_HOST}/rest/crimes/unified for Malops of the selected types
  3. Reads the sensor inventory from {CR_HOST}/rest/sensors/query, 1000 sensors per page
  4. If CR_INCLUDE_PROCESS_EVIDENCE is enabled, queries {CR_HOST}/rest/visualsearch/query/simple for each Malop's root-cause processes
  5. Maps each Malop to an [EDR] vulnerability on every affected machine:
    • Severity: the Malop's severity or priority, mapped to Faraday's scale
    • Status: open, investigating or reopened Malops become open; resolved or closed become closed; false positives, muted or excluded become risk-accepted
    • Description: detection type, activity types, root causes, affected machines and users, and sensor details
    • References: Malop GUID and type, detection type, root cause, MITRE tactics and techniques, and CVEs found in the Malop
  6. Creates one host per sensor, using its internal (or external) IP, machine name, MAC and OS

Notes

  • Sensors without Malops are imported as hosts with no vulnerabilities. Malops that cannot be matched to a sensor with an IP are placed on hosts with IP 0.0.0.0.
  • The Malop query returns at most 10,000 Malops per run.
  • The run stops if the login does not return a session cookie or the API answers 401/403.
  • An unrecognized CR_MIN_SEVERITY value falls back to info. Unknown CR_MALOP_TYPE values are sent to Cybereason unchanged.
  • The shared agent parameters (AGENT_CONFIG_* tags and severity filters) are not applied by this executor. Use CR_MIN_SEVERITY to filter by severity.