Skip to content

Patrowl Vulnerability Management Executor

Category: Threat Intelligence Script: patrowl.py Integration: REST API Faraday Plugin: Raw JSON Website: https://patrowl.io/

Description

Imports the findings of a Patrowl vulnerability management platform into Faraday. Every Patrowl finding becomes a Faraday vulnerability, with its scanner engine, affected asset, CVEs, CWEs and CVSS data.

Prerequisites

  • A Patrowl instance reachable from the agent
  • A Patrowl user (local or LDAP) that can read findings
  • requests available in the agent's Python environment (checked with python3 -c 'import requests')

Configuration

Environment Variables (Setup)

Variable Required Description
PATROWL_HOST Yes Base URL of your Patrowl instance (e.g., https://patrowl.example.com). If you omit the scheme, https:// is used.
PATROWL_USER Yes Patrowl user name
PATROWL_PASSWORD Yes Patrowl password

These variables are also accepted as execution arguments, so a single run can override them.

Execution Arguments

Parameter Type Mandatory Description
PATROWL_MIN_SEVERITY string No Minimum severity to import: info, low, medium, high or critical. Aliases such as crit, med and moderate are accepted. If empty or unrecognized, all findings are imported.
PATROWL_PAGE_SIZE integer No Number of findings requested per page (default: 100, minimum 1, maximum 500)

YAML Configuration Example

executors:
  patrowl:
    repo_executor: patrowl.py
    max_size: 65536
    varenvs:
      PATROWL_HOST: "https://patrowl.example.com"
      PATROWL_USER: "<patrowl_user>"
      PATROWL_PASSWORD: "<patrowl_password>"
    params:
      PATROWL_MIN_SEVERITY:
        mandatory: false
        type: string
        base: string
      PATROWL_PAGE_SIZE:
        mandatory: false
        type: integer
        base: integer

How It Works

  1. Sends the user name and password to POST /api/auth/login and receives a token. The run stops if no token is returned.
  2. Reads findings from GET /findings/api/v1/findings/, page by page. When PATROWL_MIN_SEVERITY is set, the API only returns findings at or above that severity.
  3. Maps each finding to a Faraday vulnerability:
    • Name: [Patrowl] [<engine>] <title> on <asset>
    • Severity: Patrowl's severity (info, low, medium, high, critical)
    • Resolution: Patrowl's solution text, or a generic triage hint
    • Details: status, engine, asset and its type, risk, CVSS score and vector, tags, and dates
    • References: CVEs, CWEs, other cross-references from Patrowl and a link to the finding in the Patrowl portal
  4. Groups all vulnerabilities under one host

Notes

  • All findings go under one host with IP 0.0.0.0 and hostname patrowl, because Patrowl assets can be URLs, domains or keywords. The real asset is in each vulnerability's name and description.
  • All vulnerabilities are created as open. Findings that Patrowl has marked as patched, closed, false-positive, mitigated or resolved are lowered to info severity, and their Patrowl status is kept in the description.
  • At most 200 pages and 10,000 findings are imported per run.
  • The shared agent parameters (AGENT_CONFIG_* tags and severity filters) are not applied by this executor. Use PATROWL_MIN_SEVERITY to filter by severity.