pensar pentests

Overview

The pensar pentests command lets you manage pentests (scans) for a project through the Pensar Console API. You can list existing pentests, view details, or dispatch new ones — all from the command line.

Usage

$pensar pentests <projectId> # List pentests for a project
$pensar pentests get <pentestId> # Get pentest details
$pensar pentests dispatch <projectId> [options] # Dispatch a new pentest

Prerequisites

You must be connected to Pensar Console via pensar auth login before using this command.

Subcommands

List Pentests

$pensar pentests <projectId>

Lists all pentests for the given project. Returns a JSON array of pentest objects.

Get Pentest Details

$pensar pentests get <pentestId>

Retrieves detailed information about a specific pentest, including status, findings count, and configuration.

Dispatch a New Pentest

$pensar pentests dispatch <projectId> [options]

Dispatches a new pentest scan for the specified project.

FlagDescription
--branch <branch>Target branch to scan
--level <level>Scan depth: priority (default) or full

Examples

$# List all pentests for a project
$pensar pentests proj_abc123
$
$# Get details for a specific pentest
$pensar pentests get scan_def456
$
$# Dispatch a new priority scan
$pensar pentests dispatch proj_abc123
$
$# Dispatch a full scan on a specific branch
$pensar pentests dispatch proj_abc123 --branch main --level full