Skip to content

Wiz (CNAPP) Executor

Category: Cloud Security Script: wiz.py Integration: GraphQL API (OAuth2) Faraday Plugin: Raw JSON Website: https://www.wiz.io/

Description

Imports cloud security issues from a Wiz tenant into Faraday. The executor queries the Wiz GraphQL API for the issues of one Wiz project and creates one Faraday vulnerability per issue, with the affected cloud resource, rule details, remediation guidance, CVEs and CWEs.

Prerequisites

  • A Wiz tenant with API access
  • A Wiz service account with permission to read issues. Wiz shows its client ID and client secret when you create it.
  • The ID (UUID) of the Wiz project to import

Configuration

Environment Variables (Setup)

Variable Required Description
WIZ_HOST Yes Wiz API URL for your tenant (e.g., https://api.us4.app.wiz.io). The region segment depends on your tenant.
WIZ_AUTH_HOST Yes Wiz authentication URL (e.g., https://auth.app.wiz.io)
WIZ_CLIENT_ID Yes Service account client ID
WIZ_CLIENT_SECRET Yes Service account client secret
WIZ_AUDIENCE No OAuth2 audience for the token request (default: wiz-api)

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

Execution Arguments

Parameter Type Mandatory Description
WIZ_PROJECT_ID string Yes ID (UUID) of the Wiz project whose issues are imported
WIZ_MIN_SEVERITY string No Minimum severity to import: info, low, medium, high or critical (default: info)
WIZ_STATUS string No Comma-separated issue statuses to import: OPEN, IN_PROGRESS, RESOLVED, REJECTED (default: all)

YAML Configuration Example

executors:
  wiz:
    repo_executor: wiz.py
    max_size: 65536
    varenvs:
      WIZ_HOST: "https://api.us4.app.wiz.io"
      WIZ_AUTH_HOST: "https://auth.app.wiz.io"
      WIZ_CLIENT_ID: "<client_id>"
      WIZ_CLIENT_SECRET: "<client_secret>"
    params:
      WIZ_PROJECT_ID:
        mandatory: true
        type: string
        base: string
      WIZ_MIN_SEVERITY:
        mandatory: false
        type: string
        base: string
      WIZ_STATUS:
        mandatory: false
        type: string
        base: string

How It Works

  1. Requests an access token from {WIZ_AUTH_HOST}/oauth/token using the OAuth2 client credentials flow
  2. Queries {WIZ_HOST}/graphql for the project's issues, filtered by status and severity, 100 per page
  3. Maps each issue to a Faraday vulnerability:
    • Name: the rule name plus the affected resource (type, name and region)
    • Severity: Wiz's severity mapped to Faraday's scale, or the CVSS score when Wiz only gives a score
    • Status: OPEN/IN_PROGRESS become open, RESOLVED becomes closed, REJECTED becomes risk-accepted
    • Resolution: the rule's remediation instructions
    • References: CVEs, CWEs, the resource's cloud console URL and any linked service tickets
  4. Groups all vulnerabilities under one host that represents the Wiz project (see Notes)

Notes

  • The executor creates a single host per run. Its IP is 0.0.0.0 and its hostname is <project name>@<project id>, because Wiz findings belong to cloud resources rather than IP addresses. The affected resource of each finding is in the vulnerability's name and description.
  • The shared agent parameters (AGENT_CONFIG_* tags and severity filters) are not applied by this executor. Use WIZ_MIN_SEVERITY to filter by severity.
  • An unrecognized WIZ_MIN_SEVERITY value falls back to info, and unrecognized WIZ_STATUS values are ignored. Both cases are written to the agent log.