This is the multi-page printable view of this section. Click here to print.

Return to the regular view of this page.

AnchoreCTL Reference

AnchoreCTL (anchorectl) is the command-line client for Anchore Enterprise. Every function available in the Anchore Enterprise UI is built on the same APIs that AnchoreCTL calls, so anything you can do in the browser you can also do from a terminal or a CI pipeline.

This is the complete reference for the AnchoreCTL command set: every command group, every subcommand, and every flag with its environment variable and default. Each top-level command group has its own page; the Command Index below links to every individual command. It describes AnchoreCTL v6.2.1; run anchorectl version to check yours.

AnchoreCTL reads its settings from a configuration file, environment variables, and command-line flags, in ascending order of precedence. This page documents the flags; for the configuration file and the full list of ANCHORECTL_* variables, see Configuring AnchoreCTL.

Command Syntax

anchorectl [command] [subcommand] [ARGUMENTS] [flags]

Arguments shown in UPPER_CASE in a command synopsis are positional and required. Anything in [square brackets] is optional. A trailing ..., as in anchorectl image delete IMAGE..., means the argument can be repeated.

In the flag tables on each page, the Flag column shows exactly what you type and the Type column shows the kind of value it takes:

TypeMeaning
boolTakes no value. The flag’s presence turns it on, as in --wait.
stringTakes one value, as in --output json.
string (repeatable)Takes one value and may be given more than once, as in --annotation owner=platform-team --annotation commit=a3f7c01.
intTakes a whole number, as in --timeout 300.
countTakes no value; repeat it to increase the effect, as in -vv.

Global Flags

These four flags are accepted by every command.

FlagTypeEnvironment variableDefaultRequiredDescription
-c, --configstringANCHORECTL_CONFIG""NoPath to the AnchoreCTL configuration file. Bypasses the default search order.
-h, --helpboolfalseNoShow help for the command and exit.
-q, --quietboolANCHORECTL_QUIETfalseNoSuppress all logging output. Results are still written to stdout.
-v, --verbosecountANCHORECTL_VERBOSITY0NoIncrease log verbosity. -v sets info, -vv sets debug. Takes precedence over log.level.

Output Formats

-o/--output selects how results are printed. It is not a global flag — it is defined per command, on 127 of the 148 commands, and the root command does not accept it at all. Values and defaults differ per command; each command’s flag table lists what it accepts. ANCHORECTL_FORMAT sets it on most of them, though anchorectl image sbom, anchorectl system artifact-lifecycle-policy add and update, and anchorectl version ignore the variable and need the flag passed explicitly.

The app version export commands are the main exception. They emit a document rather than a result listing, so they take --format for the document format and --file to write it to disk instead of stdout. anchorectl image one-time-scan likewise uses --format together with --output-directory.

ValueDescription
textHuman-readable table. The default for most commands.
jsonStructured JSON, normalized by AnchoreCTL.
json-rawThe unmodified JSON response from the Anchore Enterprise API. Use this when you need fields AnchoreCTL does not surface.
idThe identifier of the affected object only. Useful for shell pipelines.
csvComma-separated values, for export commands.
htmlSelf-contained HTML report. Set ui-url in your configuration to make the report link back to the Anchore Enterprise UI.
cyclonedx-jsonCycloneDX document in JSON form.
cyclonedx-xmlCycloneDX document in XML form.
spdx-jsonSPDX document in JSON form.
spdx-tag-valueSPDX document in tag-value form.
syft-jsonSyft’s native JSON SBOM format. The default for anchorectl image sbom.
purlsA plain list of Package URLs.
tableSyft’s table rendering of an SBOM.

Exit Codes

CodeMeaning
0The command ran successfully.
1The command failed — a request error, invalid input, or an unreachable server.

The exit code reflects whether the command itself ran, not the outcome of a policy evaluation: a fail result is still a successful command and exits 0. To make a failing evaluation break a CI build, pass -f/--fail-based-on-results to anchorectl image check or anchorectl app version policy status get, or --fail-on-policy-error to anchorectl image one-time-scan.

Command Index

Each page below documents that command’s complete subcommand tree, with every flag and argument.

  • account — Account related operations
  • airgap — Airgap related operations
  • app — App related operations
  • archive — Archive rule and image operations
  • auth — Auth related operations for the current user
  • completion — Generate the autocompletion script for anchorectl for the specified shell.
  • correction — Correction related operations
  • event — Event related operations
  • feed — Feed related operations
  • generate — Generate analysis artifacts locally
  • image — Image related operations
  • inventory — Inventory list operation
  • policy — Policy related operations
  • registry — Registry credential operations
  • repo — Repository related operations
  • stig — STIG related operations
  • subscription — Subscription related operations
  • system — System related operations
  • user — User related operations
  • usergroup — User Group Management Operations
  • version — Show anchorectl version information

1 - anchorectl account

Account related operations.

Every command on this page also accepts the global flags.

Subcommands

  • account add — Create a new account. Only available to admin user.
  • account delete — Delete the specified account, only allowed if the account is in the disabled state. All users will be deleted along with the account and all resources will be garbage collected
  • account disable — Disable an account
  • account enable — Enable a previously disabled account
  • account get — Get info about an account. Only available to admin user. Uses the main user Id, not a username.
  • account list — List account summaries. Only available to the system admin user.
  • account update — Update an account. Only available to admin user.

account add

Create a new account. Only available to admin user.

anchorectl account add NAME [flags]

Arguments

ArgumentDescription
NAMEName of the account to create.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--emailstringANCHORECTL_ACCOUNT_EMAIL""NoThe account email.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

account delete

Delete the specified account, only allowed if the account is in the disabled state. All users will be deleted along with the account and all resources will be garbage collected.

anchorectl account delete NAME [flags]

Aliases: del

Arguments

ArgumentDescription
NAMEName of the account.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

account disable

Disable an account.

anchorectl account disable NAME [flags]

Arguments

ArgumentDescription
NAMEName of the account.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

account enable

Enable a previously disabled account.

anchorectl account enable NAME [flags]

Arguments

ArgumentDescription
NAMEName of the account.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

account get

Get info about an account. Only available to admin user. Uses the main user Id, not a username.

anchorectl account get NAME [flags]

Arguments

ArgumentDescription
NAMEName of account.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

account list

List account summaries. Only available to the system admin user.

anchorectl account list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--statestringANCHORECTL_ACCOUNT_STATE""NoFilter accounts by state. Allowable values: enabled, disabled, deleting.

account update

Update an account. Only available to admin user.

anchorectl account update NAME [flags]

Arguments

ArgumentDescription
NAMEName of the account.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--emailstringANCHORECTL_ACCOUNT_EMAIL""NoThe account email.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

2 - anchorectl airgap

Airgap related operations.

Every command on this page also accepts the global flags.

Subcommands

airgap feed

Feed related operations.

anchorectl airgap feed [command]

Subcommands

airgap feed download

Check for updates to Hosted Feeds and download the latest changes.

anchorectl airgap feed download [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-f, --filestringANCHORECTL_FEEDS_FILE""NoThe file path to create or update a feedset archive.
-k, --keystringANCHORECTL_API_KEY""NoThe API key to authorize the request.
-l, --licensestringANCHORECTL_LICENSE_FILE""NoThe path to an Anchore license file.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw. See Output Formats.
-r, --retriesintANCHORECTL_RETRIES3NoThe number of times to retry a failed download.

airgap feed upload

Upload the specified feedset into Anchore Enterprise.

anchorectl airgap feed upload [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-f, --filestringANCHORECTL_INPUT_FILE""YesPath to a previously downloaded feedset archive.
--forceboolANCHORECTL_FORCEfalseNoPerform feed upload even if checksums match.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw. See Output Formats.

3 - anchorectl app

App related operations.

Every command on this page also accepts the global flags.

Subcommands

app add

Create a new app.

anchorectl app add NAME [flags]

Arguments

ArgumentDescription
NAMEThe name of the app.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--contact-namestringANCHORECTL_CONTACT_NAME""YesContact person name.
--contact-emailstringANCHORECTL_CONTACT_EMAIL""NoContact email address.
--contact-phonestringANCHORECTL_CONTACT_PHONE""NoContact phone number.
--descriptionstringANCHORECTL_DESCRIPTION""NoThe description of the app.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--policy-idstringANCHORECTL_POLICY_ID""NoThe policy name or ID to associate with the app.

app delete

Delete an app by name or ID.

anchorectl app delete APP [flags]

Aliases: del

Arguments

ArgumentDescription
APPThe app name or ID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--forceboolANCHORECTL_FORCEfalseNoForce delete (removes all versions and associations).
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app get

Get an app by name or ID.

anchorectl app get APP [flags]

Arguments

ArgumentDescription
APPThe app name or ID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app job

Job operations for an app.

anchorectl app job [command]

Subcommands

  • app job cancel — Cancel a job
  • app job get — Get a job by ID. Pass --detail with -o json-raw to fetch the type-specific job payload (job_spec, completion_detail, etc.).
  • app job list — List jobs for an app

app job cancel

Cancel a job.

anchorectl app job cancel JOB_ID [flags]

Arguments

ArgumentDescription
JOB_IDThe job UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app job get

Get a job by ID. Pass --detail with -o json-raw to fetch the type-specific job payload (job_spec, completion_detail, etc.).

anchorectl app job get JOB_ID [flags]

Arguments

ArgumentDescription
JOB_IDThe job UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--detailboolANCHORECTL_DETAILfalseNoFetch the type-specific job payload (requires -o json-raw).
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app job list

List jobs for an app.

anchorectl app job list APP [flags]

Arguments

ArgumentDescription
APPThe app name or ID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--created-sincestringANCHORECTL_CREATED_SINCE""NoOnly show jobs created since: Go duration syntax (units s/m/h, e.g. “30m”, “1h”, “2h45m”, “1.5h”) or a datetime (“2026-04-15”, “2026-04-15 09:00:00”, “2026-04-15T09:00:00Z”). Bare datetimes are interpreted in local time.
--mineboolANCHORECTL_MINEfalseNoOnly show jobs owned by the current user.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--statusstring (repeatable)ANCHORECTL_STATUS[]NoFilter by job status (comma-separated for multiple, OR semantics). Allowable values: pending, processing, cancelled, complete, failed.
--versionstringANCHORECTL_VERSION""NoFilter by version name or UUID.

app list

List all apps.

anchorectl app list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--namestringANCHORECTL_NAME""NoFilter by exact app name.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app update

Update an existing app.

anchorectl app update APP [flags]

Arguments

ArgumentDescription
APPThe app name or ID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--contact-emailstringANCHORECTL_CONTACT_EMAIL""NoContact email address.
--contact-namestringANCHORECTL_CONTACT_NAME""NoContact person name.
--contact-phonestringANCHORECTL_CONTACT_PHONE""NoContact phone number.
--descriptionstringANCHORECTL_DESCRIPTION""NoThe new description.
--namestringANCHORECTL_NAME""NoThe new name for the app.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--policy-idstringANCHORECTL_POLICY_ID""NoThe policy name or ID to associate.

app version

App version related operations.

anchorectl app version [command]

Subcommands

app version add

Create a new app version.

anchorectl app version add NAME [flags]

Arguments

ArgumentDescription
NAMEThe name of the version.

Examples

# Create a released version of an app
anchorectl app version add 1.4.0 --app my-service --status released

# Create the next version and chain it to its predecessor
anchorectl app version add 1.5.0 --app my-service --status in_progress --previous-version 1.4.0

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--descriptionstringANCHORECTL_DESCRIPTION""NoThe version description.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--previous-versionstringANCHORECTL_PREVIOUS_VERSION""NoThe previous version name or UUID.
--release-datestringANCHORECTL_RELEASE_DATE""NoDate of release of this version (e.g. 2026-01-15).
--statusstringANCHORECTL_STATUS""NoThe status of the app version (in_progress, released, eol).

app version asset

App version asset operations.

anchorectl app version asset [command]

Subcommands

app version asset add

Add an asset to an app version.

anchorectl app version asset add [command]

Subcommands

  • app version asset add analysis-bundle — Upload an analysis bundle produced by anchorectl generate analysis-bundle as an asset to an app version. Creates a job to import and process the analysis.
  • app version asset add container-image — Add a container image as an asset. By default pulls from a registry. Use --from docker or --from podman to analyze a local daemon image, or --from docker-archive:/path/to.tar to load from an archive.
  • app version asset add container-image-remote — Add a container image via centralized analysis. Enterprise pulls and analyzes the image from the registry.
  • app version asset add filesystem — Add a filesystem directory as an asset. Analyzes the directory locally using Syft, generates an SBOM, and uploads it to Enterprise.
  • app version asset add sbom — Upload an SBOM file as an asset to an app version. Creates a job to import and process the SBOM.

app version asset add analysis-bundle

Upload an analysis bundle produced by anchorectl generate analysis-bundle as an asset to an app version. Creates a job to import and process the analysis.

anchorectl app version asset add analysis-bundle BUNDLE [flags]

Arguments

ArgumentDescription
BUNDLEPath to the analysis bundle tar archive (uncompressed; typically named .tar).

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--assetstringANCHORECTL_ASSET""YesThe name for the new asset.
--versionstringANCHORECTL_VERSION""YesThe version name or UUID.
-a, --annotationsstringANCHORECTL_ANNOTATIONS""NoAnnotations as comma-separated key=value pairs.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
-t, --typestringANCHORECTL_TYPEunknownNoThe asset type (image analysis bundles default to container).
-w, --waitboolANCHORECTL_WAITfalseNoWait for the job to complete before returning.

app version asset add container-image

Add a container image as an asset. By default pulls from a registry. Use --from docker or --from podman to analyze a local daemon image, or --from docker-archive:/path/to.tar to load from an archive.

anchorectl app version asset add container-image IMAGE [flags]

Arguments

ArgumentDescription
IMAGEThe container image reference (e.g. docker.io/library/nginx:latest).

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--assetstringANCHORECTL_ASSET""YesThe name for the new asset.
--versionstringANCHORECTL_VERSION""YesThe version name or UUID.
-a, --annotationsstringANCHORECTL_ANNOTATIONS""NoAnnotations as comma-separated key=value pairs.
--dockerfilestringANCHORECTL_DOCKERFILE""NoPath to the Dockerfile used to build the image.
--fromstringANCHORECTL_FROM""NoImage source: registry (default), docker, podman, or docker-archive:<path> (docker and podman: if the image is not present in the daemon it is pulled from the registry).
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
-p, --platformstringANCHORECTL_PLATFORM""NoPlatform specifier (e.g. linux/amd64).
-t, --typestringANCHORECTL_TYPEcontainerNoThe asset type.
-w, --waitboolANCHORECTL_WAITfalseNoWait for the job to complete before returning.

app version asset add container-image-remote

Add a container image via centralized analysis. Enterprise pulls and analyzes the image from the registry.

anchorectl app version asset add container-image-remote IMAGE [flags]

Arguments

ArgumentDescription
IMAGEThe container image reference (e.g. docker.io/library/nginx:latest).

Examples

anchorectl app version asset add container-image-remote registry.example.com/my-service:1.4.0 \
  --app my-service --version 1.4.0 --asset api-image --wait

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--assetstringANCHORECTL_ASSET""YesThe name for the new asset.
--versionstringANCHORECTL_VERSION""YesThe version name or UUID.
-a, --annotationsstringANCHORECTL_ANNOTATIONS""NoAnnotations as comma-separated key=value pairs.
--dockerfilestringANCHORECTL_DOCKERFILE""NoPath to the Dockerfile used to build the image.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
-t, --typestringANCHORECTL_TYPEcontainerNoThe asset type.
-w, --waitboolANCHORECTL_WAITfalseNoWait for the job to complete before returning.

app version asset add filesystem

Add a filesystem directory as an asset. Analyzes the directory locally using Syft, generates an SBOM, and uploads it to Enterprise.

anchorectl app version asset add filesystem DIRECTORY [flags]

Arguments

ArgumentDescription
DIRECTORYThe path to the directory to analyze (e.g. /mnt/unpacked-vm, ./myapp).

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--assetstringANCHORECTL_ASSET""YesThe name for the new asset.
--versionstringANCHORECTL_VERSION""YesThe version name or UUID.
-a, --annotationsstringANCHORECTL_ANNOTATIONS""NoAnnotations as comma-separated key=value pairs.
--authorstringANCHORECTL_AUTHORunknownNoSBOM document author (e.g. “Name <email>”).
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--supplierstringANCHORECTL_SUPPLIERunknownNoSBOM document supplier name.
-t, --typestringANCHORECTL_TYPEfilesystemNoThe asset type.
-w, --waitboolANCHORECTL_WAITfalseNoWait for the job to complete before returning.

app version asset add sbom

Upload an SBOM file as an asset to an app version. Creates a job to import and process the SBOM.

anchorectl app version asset add sbom SBOM_FILE [flags]

Arguments

ArgumentDescription
SBOM_FILEPath to the SBOM file.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--assetstringANCHORECTL_ASSET""YesThe name for the new asset.
--versionstringANCHORECTL_VERSION""YesThe version name or UUID.
-a, --annotationsstringANCHORECTL_ANNOTATIONS""NoAnnotations as comma-separated key=value pairs.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
-t, --typestringANCHORECTL_TYPEunknownNoThe asset type.
-w, --waitboolANCHORECTL_WAITfalseNoWait for the job to complete before returning.

app version asset delete

Delete an asset from an app version.

anchorectl app version asset delete ASSET [flags]

Arguments

ArgumentDescription
ASSETThe asset name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--versionstringANCHORECTL_VERSION""YesThe version name or UUID.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app version asset get

Get an asset by ID for an app version.

anchorectl app version asset get ASSET [flags]

Arguments

ArgumentDescription
ASSETThe asset name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--versionstringANCHORECTL_VERSION""YesThe version name or UUID.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app version asset list

List assets for an app version.

anchorectl app version asset list VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--namestringANCHORECTL_NAME""NoFilter by asset name.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app version asset sbom

App version asset SBOM operations.

anchorectl app version asset sbom [command]

Subcommands

app version asset sbom get

Get the SBOM for an asset in an app version.

anchorectl app version asset sbom get ASSET [flags]

Arguments

ArgumentDescription
ASSETThe asset name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--versionstringANCHORECTL_VERSION""YesThe version name or UUID.
-f, --filestringANCHORECTL_FILE""NoWrite SBOM to file instead of stdout.

app version asset update

Update an asset for an app version.

anchorectl app version asset update ASSET [flags]

Arguments

ArgumentDescription
ASSETThe asset name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--versionstringANCHORECTL_VERSION""YesThe version name or UUID.
--annotationsstringANCHORECTL_ANNOTATIONS""NoAnnotations as comma-separated key=value pairs (merge with existing, set value to empty to remove).
--namestringANCHORECTL_NAME""NoThe new name for the asset.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--typestringANCHORECTL_TYPE""NoThe asset type.

app version delete

Delete an app version by name or ID.

anchorectl app version delete VERSION [flags]

Aliases: del

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--forceboolANCHORECTL_FORCEfalseNoForce delete (removes all associations).

app version export

Export documents for an app version.

anchorectl app version export [command]

Subcommands

  • app version export packages — Export package data for an app version. Creates an export job, waits for completion, and outputs the result.
  • app version export policy-compliance — Export policy compliance findings for an app version. Creates an export job, waits for completion, and outputs the result.
  • app version export sbom-cyclonedx-1 — Export a combined CycloneDX 1.x JSON SBOM for an app version. Creates an export job, waits for completion, and outputs the result.
  • app version export sbom-spdx-2 — Export a combined SPDX 2.x JSON SBOM for an app version. Creates an export job, waits for completion, and outputs the result.
  • app version export vdr — Export a CycloneDX VDR (Vulnerability Disclosure Report) for an app version. Creates an export job, waits for completion, and outputs the result.
  • app version export vex — Export VEX (Vulnerability Exploitability eXchange) annotations for an app version. Creates an export job, waits for completion, and outputs the result.
  • app version export vulnerabilities — Export vulnerability data for an app version. Creates an export job, waits for completion, and outputs the result.

app version export packages

Export package data for an app version. Creates an export job, waits for completion, and outputs the result.

anchorectl app version export packages VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-f, --filestringANCHORECTL_FILE""NoWrite output to file instead of stdout.
--formatstringANCHORECTL_FORMATcsvNoThe export format. Allowable values: csv.

app version export policy-compliance

Export policy compliance findings for an app version. Creates an export job, waits for completion, and outputs the result.

anchorectl app version export policy-compliance VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-f, --filestringANCHORECTL_FILE""NoWrite output to file instead of stdout.
--formatstringANCHORECTL_FORMATcsvNoThe export format. Allowable values: csv.

app version export sbom-cyclonedx-1

Export a combined CycloneDX 1.x JSON SBOM for an app version. Creates an export job, waits for completion, and outputs the result.

anchorectl app version export sbom-cyclonedx-1 VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-f, --filestringANCHORECTL_FILE""NoWrite output to file instead of stdout.

app version export sbom-spdx-2

Export a combined SPDX 2.x JSON SBOM for an app version. Creates an export job, waits for completion, and outputs the result.

anchorectl app version export sbom-spdx-2 VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-f, --filestringANCHORECTL_FILE""NoWrite output to file instead of stdout.

app version export vdr

Export a CycloneDX VDR (Vulnerability Disclosure Report) for an app version. Creates an export job, waits for completion, and outputs the result.

anchorectl app version export vdr VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-f, --filestringANCHORECTL_FILE""NoWrite output to file instead of stdout.
--formatstringANCHORECTL_FORMATcyclonedx-jsonNoThe export format. Allowable values: cyclonedx-json.

app version export vex

Export VEX (Vulnerability Exploitability eXchange) annotations for an app version. Creates an export job, waits for completion, and outputs the result.

anchorectl app version export vex VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-f, --filestringANCHORECTL_FILE""NoWrite output to file instead of stdout.
--formatstringANCHORECTL_FORMATcyclonedx-jsonNoThe export format. Allowable values: cyclonedx-json.

app version export vulnerabilities

Export vulnerability data for an app version. Creates an export job, waits for completion, and outputs the result.

anchorectl app version export vulnerabilities VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-f, --filestringANCHORECTL_FILE""NoWrite output to file instead of stdout.
--formatstringANCHORECTL_FORMATcsvNoThe export format. Allowable values: csv.

app version get

Get an app version by name or ID.

anchorectl app version get VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app version list

List all versions of an app.

anchorectl app version list APP [flags]

Arguments

ArgumentDescription
APPThe app name or ID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--namestringANCHORECTL_NAME""NoFilter by exact version name.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app version package

App version package operations.

anchorectl app version package [command]

Subcommands

app version package list

List packages for an app version.

anchorectl app version package list VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app version policy

App version policy operations.

anchorectl app version policy [command]

Subcommands

app version policy findings

App version policy findings operations.

anchorectl app version policy findings [command]

Subcommands

app version policy findings list

List policy findings for an app version.

anchorectl app version policy findings list VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app version policy status

App version policy status operations.

anchorectl app version policy status [command]

Subcommands

app version policy status get

Get policy evaluation status for an app version.

anchorectl app version policy status get VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-f, --fail-based-on-resultsboolANCHORECTL_FAIL_BASED_ON_RESULTSfalseNoSet the return code to 1 if the policy evaluation result shows as fail.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app version update

Update an existing app version.

anchorectl app version update VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--descriptionstringANCHORECTL_DESCRIPTION""NoThe new description.
--namestringANCHORECTL_NAME""NoThe new name for the version.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--previous-versionstringANCHORECTL_PREVIOUS_VERSION""NoThe previous version name or UUID.
--release-datestringANCHORECTL_RELEASE_DATE""NoDate of release of this version (e.g. 2026-01-15).
--statusstringANCHORECTL_STATUS""NoThe status of the app version (in_progress, released, eol).

app version vex

VEX annotation operations for an app version.

anchorectl app version vex [command]

Subcommands

app version vex add

Add a VEX annotation to an app version.

anchorectl app version vex add VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--pkg-namestringANCHORECTL_PKG_NAME""YesThe package name.
--pkg-typestringANCHORECTL_PKG_TYPE""YesThe package type (e.g. java-archive, npm, python).
--pkg-versionstringANCHORECTL_PKG_VERSION""YesThe package version.
--statusstringANCHORECTL_STATUS""YesThe VEX status. Allowable values: not_affected, affected, fixed, under_investigation.
--vuln-idstringANCHORECTL_VULN_ID""YesThe vulnerability ID (e.g. CVE-2021-44228).
--action-statementstringANCHORECTL_ACTION_STATEMENT""NoAction statement for remediation.
--additional-detailsstringANCHORECTL_ADDITIONAL_DETAILS""NoFree-form additional details.
--impact-statementstringANCHORECTL_IMPACT_STATEMENT""NoImpact statement for the vulnerability.
--justificationstringANCHORECTL_JUSTIFICATION""NoJustification for not_affected status. Allowable values: component_not_present, vulnerable_code_not_present, vulnerable_code_not_in_execute_path, vulnerable_code_cannot_be_controlled_by_adversary, inline_mitigations_already_exist.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--status-notesstringANCHORECTL_STATUS_NOTES""NoAdditional notes about the status.

app version vex delete

Delete a VEX annotation.

anchorectl app version vex delete VULN_ANNOTATION_ID [flags]

Aliases: del

Arguments

ArgumentDescription
VULN_ANNOTATION_IDThe VEX annotation UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--versionstringANCHORECTL_VERSION""YesThe version name or UUID.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app version vex get

Get a VEX annotation by ID.

anchorectl app version vex get VULN_ANNOTATION_ID [flags]

Arguments

ArgumentDescription
VULN_ANNOTATION_IDThe VEX annotation UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--versionstringANCHORECTL_VERSION""YesThe version name or UUID.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app version vex list

List VEX annotations for an app.

anchorectl app version vex list VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

app version vex update

Update a VEX annotation.

anchorectl app version vex update VULN_ANNOTATION_ID [flags]

Arguments

ArgumentDescription
VULN_ANNOTATION_IDThe VEX annotation UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
--versionstringANCHORECTL_VERSION""YesThe version name or UUID.
--action-statementstringANCHORECTL_ACTION_STATEMENT""NoAction statement for remediation.
--additional-detailsstringANCHORECTL_ADDITIONAL_DETAILS""NoFree-form additional details.
--impact-statementstringANCHORECTL_IMPACT_STATEMENT""NoImpact statement for the vulnerability.
--justificationstringANCHORECTL_JUSTIFICATION""NoJustification for not_affected status. Allowable values: component_not_present, vulnerable_code_not_present, vulnerable_code_not_in_execute_path, vulnerable_code_cannot_be_controlled_by_adversary, inline_mitigations_already_exist.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--statusstringANCHORECTL_STATUS""NoThe VEX status. Allowable values: not_affected, affected, fixed, under_investigation.
--status-notesstringANCHORECTL_STATUS_NOTES""NoAdditional notes about the status.

app version vuln

App version vulnerability operations.

anchorectl app version vuln [command]

Subcommands

app version vuln list

List vulnerabilities for an app version.

anchorectl app version vuln list VERSION [flags]

Arguments

ArgumentDescription
VERSIONThe version name or UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--appstringANCHORECTL_APP""YesThe app name or ID.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw. See Output Formats.

4 - anchorectl archive

Archive rule and image operations.

Every command on this page also accepts the global flags.

Subcommands

archive image

Archive image related operations.

anchorectl archive image [command]

Subcommands

archive image add

Archive images.

anchorectl archive image add IMAGE_DIGESTS [flags]

Arguments

ArgumentDescription
IMAGE_DIGESTSList of image digests to archive.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

archive image delete

Performs a synchronous archive deletion.

anchorectl archive image delete IMAGEDIGEST [flags]

Aliases: del

Arguments

ArgumentDescription
IMAGEDIGESTImage digest to delete from archive.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--forceboolANCHORECTL_ARCHIVE_IMAGE_FORCEfalseNoForce archive image deletion.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

archive image get

Returns the archive metadata record identifying the image and tags for the analysis in the archive.

anchorectl archive image get IMAGE_DIGEST [flags]

Arguments

ArgumentDescription
IMAGE_DIGESTThe image digest to identify the image analysis.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

archive image list

List archived images.

anchorectl archive image list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

archive image restore

Creates a new analysis task that is executed asynchronously.

anchorectl archive image restore DIGEST [flags]

Arguments

ArgumentDescription
DIGESTThe image digest identify the analysis. Archived analyses are based on digest, tag records are restored as analysis is restored.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--forceboolANCHORECTL_ARCHIVE_IMAGE_FORCEfalseNoOverride any existing entry in the system.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

archive rule

Archive rule related operations.

anchorectl archive rule [command]

Subcommands

archive rule add

Add an analysis archive rule.

anchorectl archive rule add [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--transitionstringANCHORECTL_ARCHIVE_RULE_TRANSITION""YesThe type of transition to make. If “archive”, then archive an image from the working set and remove it from the working set. If “delete”, then match against archived images and delete from the archive if match. Allowable values: archive, delete.
--analysis-age-daysintANCHORECTL_ARCHIVE_RULE_ANALYSIS_AGE_DAYS0NoMatches if the analysis is strictly older than this number of days.
--exclude-expiration-daysintANCHORECTL_ARCHIVE_RULE_EXCLUDE_EXPIRATION_DAYS0NoHow long the image selected will be excluded from the archive transition.
--exclude-last-seen-in-daysintANCHORECTL_ARCHIVE_RULE_EXCLUDE_LAST_SEEN_IN_DAYS0NoExclude image from archive if last seen in inventory within defined number of days.
--exclude-selector-registrystringANCHORECTL_ARCHIVE_RULE_EXCLUDE_SELECTOR_REGISTRY""NoThe registry section of a pull string. e.g. with “docker.io/anchore/anchore-engine:latest”, this is “docker.io”.
--exclude-selector-repositorystringANCHORECTL_ARCHIVE_RULE_EXCLUDE_SELECTOR_REPOSITORY""NoThe repository section of a pull string. e.g. with “docker.io/anchore/anchore-engine:latest”, this is “anchore/anchore-engine”.
--exclude-selector-tagstringANCHORECTL_ARCHIVE_RULE_EXCLUDE_SELECTOR_TAG""NoThe tag-only section of a pull string. e.g. with “docker.io/anchore/anchore-engine:latest”, this is “latest”.
-i, --inputstringANCHORECTL_INPUT""NoPath to a JSON input file or - to read from stdin.
--max-images-per-accountintANCHORECTL_ARCHIVE_RULE_MAX_IMAGES_PER_ACCOUNT0NoThis is the maximum number of image analyses an account can have. Can only be set on system_global rules.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--rule-idstringANCHORECTL_ARCHIVE_RULE_RULE_ID""NoUnique identifier for archive rule.
--selector-registrystringANCHORECTL_ARCHIVE_RULE_SELECTOR_REGISTRY*NoThe registry section of a pull string. e.g. with “docker.io/anchore/anchore-engine:latest”, this is “docker.io”.
--selector-repositorystringANCHORECTL_ARCHIVE_RULE_SELECTOR_REPOSITORY*NoThe repository section of a pull string. e.g. with “docker.io/anchore/anchore-engine:latest”, this is “anchore/anchore-engine”.
--selector-tagstringANCHORECTL_ARCHIVE_RULE_SELECTOR_TAG*NoThe tag-only section of a pull string. e.g. with “docker.io/anchore/anchore-engine:latest”, this is “latest”.
--system-globalboolANCHORECTL_ARCHIVE_RULE_SYSTEM_GLOBALfalseNoTrue if the rule applies to all accounts in the system. This is only available to admin users to update/modify, but all users with permission to list rules can see them.
--tag-versions-newerintANCHORECTL_ARCHIVE_RULE_TAG_VERSIONS_NEWER0NoNumber of images mapped to the tag that are newer.

archive rule delete

Delete an analysis archive rule.

anchorectl archive rule delete ID [flags]

Aliases: del

Arguments

ArgumentDescription
IDThe rule id.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

archive rule get

Get an analysis archive rule.

anchorectl archive rule get ID [flags]

Arguments

ArgumentDescription
IDThe rule id.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

archive rule list

List the analysis archive rules.

anchorectl archive rule list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--globalboolANCHORECTL_ARCHIVE_RULE_GLOBALtrueNoInclude system global rules (owned by admin) even for non-admin users.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

5 - anchorectl auth

Auth related operations for the current user.

Every command on this page also accepts the global flags.

Subcommands

auth set-password

Set the password for the current user.

anchorectl auth set-password [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

6 - anchorectl completion

Generate the autocompletion script for anchorectl for the specified shell. See each sub-command’s help for details on how to use the generated script.

Every command on this page also accepts the global flags.

Subcommands

completion bash

Generate the autocompletion script for the bash shell.

This script depends on the bash-completion package. If it is not installed already, you can install it via your OS’s package manager.

To load completions in your current shell session:

source <(anchorectl completion bash)

To load completions for every new session, execute once:

Linux

anchorectl completion bash > /etc/bash_completion.d/anchorectl

macOS

anchorectl completion bash > $(brew --prefix)/etc/bash_completion.d/anchorectl

You will need to start a new shell for this setup to take effect.

anchorectl completion bash

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--no-descriptionsboolfalseNoDisable completion descriptions.

completion fish

Generate the autocompletion script for the fish shell.

To load completions in your current shell session:

anchorectl completion fish | source

To load completions for every new session, execute once:

anchorectl completion fish > ~/.config/fish/completions/anchorectl.fish

You will need to start a new shell for this setup to take effect.

anchorectl completion fish [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--no-descriptionsboolfalseNoDisable completion descriptions.

completion powershell

Generate the autocompletion script for powershell.

To load completions in your current shell session:

anchorectl completion powershell | Out-String | Invoke-Expression

To load completions for every new session, add the output of the above command to your powershell profile.

anchorectl completion powershell [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--no-descriptionsboolfalseNoDisable completion descriptions.

completion zsh

Generate the autocompletion script for the zsh shell.

If shell completion is not already enabled in your environment you will need to enable it. You can execute the following once:

echo "autoload -U compinit; compinit" >> ~/.zshrc

To load completions in your current shell session:

source <(anchorectl completion zsh)

To load completions for every new session, execute once:

Linux

anchorectl completion zsh > "${fpath[1]}/_anchorectl"

macOS

anchorectl completion zsh > $(brew --prefix)/share/zsh/site-functions/_anchorectl

You will need to start a new shell for this setup to take effect.

anchorectl completion zsh [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--no-descriptionsboolfalseNoDisable completion descriptions.

7 - anchorectl correction

Correction related operations.

Every command on this page also accepts the global flags.

Subcommands

correction add

Add a correction record that will be used to fix false positive vulnerabilities.

anchorectl correction add [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--descriptionstringANCHORECTL_CORRECTION_DESCRIPTION""NoOptional description of this correction rule.
-i, --inputstringANCHORECTL_INPUT""NoPath to a JSON input file or - to read from stdin.
--matchstring (repeatable)ANCHORECTL_CORRECTION_MATCH[]NoMatches of the form key=value (e.g. package=spring-core).
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--replacestring (repeatable)ANCHORECTL_CORRECTION_REPLACE[]NoReplacements of the form key=value (e.g. cpes=cpe:2.3:a:pivotal_software:spring_framework:3.2.14:::::::*).
--typestringANCHORECTL_CORRECTION_TYPE""NoType of match [supports os, npm, gem, python, java, go].

correction delete

Delete a single correction, looked up via it’s uuid.

anchorectl correction delete ID [flags]

Aliases: del

Arguments

ArgumentDescription
IDThe correction ID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

correction get

Returns a single correction, looked up via it’s uuid.

anchorectl correction get ID [flags]

Arguments

ArgumentDescription
IDThe correction ID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

correction list

Returns a list of corrections.

anchorectl correction list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

8 - anchorectl event

Event related operations.

Every command on this page also accepts the global flags.

Subcommands

  • event delete — Delete an event by its event ID or set of filters
  • event get — Lookup an event by its event ID
  • event list — Returns a paginated list of events in the descending order of their occurrence. Optional query parameters may be used for filtering results

event delete

Delete an event by its event ID or set of filters.

anchorectl event delete EVENT_ID [flags]

Aliases: del

Arguments

ArgumentDescription
EVENT_IDId of event to delete.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--allboolfalseNoDelete all events.
--beforestringANCHORECTL_EVENT_BEFORE""NoDelete events that occurred before the timestamp.
--forceboolANCHORECTL_EVENT_FORCEfalseNoForce without prompt.
--levelstringANCHORECTL_EVENT_LEVEL""NoDelete events that match the level - INFO or ERROR.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--sincestringANCHORECTL_EVENT_SINCE""NoDelete events that occurred after the timestamp.

event get

Lookup an event by its event ID.

anchorectl event get ID [flags]

Arguments

ArgumentDescription
IDEvent ID of the event for lookup.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

event list

Returns a paginated list of events in the descending order of their occurrence. Optional query parameters may be used for filtering results.

anchorectl event list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--allboolANCHORECTL_EVENT_ALLfalseNoReturn all events.
--beforestringANCHORECTL_EVENT_BEFORE""NoReturn events that occurred before the ISO8601 formatted UTC timestamp.
--event-typestringANCHORECTL_EVENT_TYPE""NoFilter events by a prefix match on the event type (e.g. “user.image.”).
--hoststringANCHORECTL_EVENT_SOURCE_HOST_ID""NoFilter events by the originating host ID.
--levelstringANCHORECTL_EVENT_LEVEL""NoFilter events by the level - INFO or ERROR.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--pageintANCHORECTL_PAGE0NoReturn the nth page of results starting from 1. Defaults to first page if left empty.
--resource-idstringANCHORECTL_EVENT_RESOURCE_ID""NoFilter events by a specified resource ID.
--resource-typestringANCHORECTL_EVENT_RESOURCE_TYPE""NoFilter events by the type of resource - tag, imageDigest, repository etc.
--servicestringANCHORECTL_EVENT_SOURCE_SERVICE_NAME""NoFilter events by the originating service.
--sincestringANCHORECTL_EVENT_SINCE""NoReturn events that occurred after the ISO8601 formatted UTC timestamp.

9 - anchorectl feed

Feed related operations.

Every command on this page also accepts the global flags.

Subcommands

  • feed list — Return a list of feed and their groups along with update and record count information. This data reflects the state of the policy engine, not the upstream feed service itself.
  • feed sync — Execute a synchronous update all the datasets. The response will block until complete.

feed list

Return a list of feed and their groups along with update and record count information. This data reflects the state of the policy engine, not the upstream feed service itself.

anchorectl feed list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

feed sync

Execute a synchronous update all the datasets. The response will block until complete.

anchorectl feed sync [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-f, --force_syncboolANCHORECTL_FORCE_SYNCfalseNoForce the feed sync to occur.
-t, --timeoutintANCHORECTL_TIMEOUT-1NoThe maximum time to wait for the feed sync to complete.

10 - anchorectl generate

Generate analysis artifacts locally.

Every command on this page also accepts the global flags.

Subcommands

generate analysis-bundle

Generate an analysis bundle from a source.

anchorectl generate analysis-bundle [command]

Subcommands

  • generate analysis-bundle filesystem — Generate an analysis bundle (an uncompressed tar archive containing the SBOM) for a local filesystem directory
  • generate analysis-bundle image — Run a full local analysis of a container image (SBOM, secrets, content search, file contents, manifests) and package the result set into an analysis bundle for later upload with app version asset add analysis.

generate analysis-bundle filesystem

Generate an analysis bundle (an uncompressed tar archive containing the SBOM) for a local filesystem directory.

anchorectl generate analysis-bundle filesystem SOURCE [flags]

Arguments

ArgumentDescription
SOURCEPath to the directory to analyze.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-f, --output-filestringANCHORECTL_OUTPUT_FILE""YesFile to write the analysis bundle tar archive (uncompressed; typically named .tar).
-o, --outputstringANCHORECTL_FORMATsyft-jsonNoThe SBOM format inside the bundle, options: cyclonedx-json, cyclonedx-xml, spdx-json, spdx-tag-value, syft-json. See Output Formats.
--overwriteboolANCHORECTL_OVERWRITEfalseNoOverwrite the output file if it exists.

generate analysis-bundle image

Run a full local analysis of a container image (SBOM, secrets, content search, file contents, manifests) and package the result set into an analysis bundle for later upload with app version asset add analysis.

anchorectl generate analysis-bundle image IMAGE [flags]

Arguments

ArgumentDescription
IMAGEThe image reference to analyze.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-f, --output-filestringANCHORECTL_OUTPUT_FILE""YesWrite the analysis bundle tar archive to this file.
--fromstringANCHORECTL_FROM""NoThe image source: registry (default), docker, podman, or docker-archive:<path> (docker and podman: if the image is not present in the daemon it is pulled from the registry).
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json. See Output Formats.
--overwriteboolANCHORECTL_OVERWRITEfalseNoOverwrite the output file if it exists.
--platformstringANCHORECTL_PLATFORM""NoPlatform to analyze for multi-arch images, e.g. linux/amd64.

11 - anchorectl image

Image related operations.

Every command on this page also accepts the global flags.

Subcommands

image add

Analyze a container image.

anchorectl image add IMAGE [flags]

Arguments

ArgumentDescription
IMAGEThe container image to analyze (e.g. docker.io/library/nginx:latest).

Examples

# Submit image for addition to Anchore Enterprise (Anchore Enterprise will pull
# image from registry and perform full analysis)

anchorectl image add ghcr.io/place/thing:v0.1.0

# Submit image for addition to Anchore Enterprise (anchorectl will perform full
# local image analysis, SBOM + additional analysis pushed to Anchore Enterprise)

anchorectl image add ghcr.io/place/thing:v0.1.0 --from docker

# Submit image for addition to Anchore Enterprise (anchorectl will perform full
# local image analysis from a local podman daemon image, SBOM + additional
# analysis pushed to Anchore Enterprise; falls back to the registry if the image
# is not present in the local podman daemon)

anchorectl image add ghcr.io/place/thing:v0.1.0 --from podman

# Submit image for addition to Anchore Enterprise (use SBOM generated by Syft,
# no additional analysis performed, and push to Anchore Enterprise)

syft -o json ghcr.io/place/thing:v0.1.0 | anchorectl image add ghcr.io/place/thing:v0.1.0 --from -

# Submit and wait for analysis to complete

anchorectl image add ghcr.io/place/thing:v0.1.0 --wait

# Submit and get results once analysis is completed

anchorectl image add ghcr.io/place/thing:v0.1.0 --get content,vulnerabilities=/path/to/vulns.json

# Submit and fetch all results to a directory

anchorectl image add ghcr.io/place/thing:v0.1.0 --get all=/path/to/dir

# Submit image for addition to Anchore Enterprise and perform a STIG evaluation locally

anchorectl image add ghcr.io/place/thing:v0.1.0 --stig --stig-profile /path/to/profile --stig-input-file /path/to/inputfile

# Associate the added image with an app version (preferred v6 path; the
# --application/-a flag on this command is deprecated and will be removed
# in a future release)

anchorectl app version asset add container-image-remote ghcr.io/place/thing:v0.1.0 --app myapp --version v3.1.4 --asset thing

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--annotationstring (repeatable)ANCHORECTL_IMAGE_ANNOTATION[]NoOne or more key-value annotations to add on the image in Anchore Enterprise (format: key=value).
-a, --applicationstringANCHORECTL_APPLICATION""NoDeprecated. Associate the image with an application at a specific version in the format app@version (example: [email protected]); use anchorectl app version asset add container-image-remote instead.
-d, --dockerfilestringANCHORECTL_IMAGE_DOCKERFILE""NoPath to the Dockerfile for this image.
-f, --forceboolANCHORECTL_FORCEfalseNoRe-analyze the image even if it has already been analyzed.
--fromstringANCHORECTL_IMAGE_FROM""NoAnalyze from the given source (default: "", indicating that Anchore Enterprise will pull the image from the registry; allowable-values: <path-to-syft-SBOM>, -, docker, podman, registry, docker-archive) (docker and podman: if the image is not present in the daemon it is pulled from the registry).
-g, --getstring (repeatable)ANCHORECTL_IMAGE_GET[]NoGet results and optionally write the raw results to a file (example: content or content=./path/to/file.json or all=/path/to/dir; allowable-keys: image-metadata, sbom, sbomspdx, sbomcyclonedx, content, vulnerability, policy-evaluation, all).
-n, --no-auto-subscribeboolANCHORECTL_IMAGE_NO_AUTO_SUBSCRIBEfalseNoDo not automatically scan newly pushed tags to the registry for the given image.
-p, --platformstringANCHORECTL_IMAGE_PLATFORM""NoAn optional platform specifier for use with --from registry target type (e.g. linux/arm64, linux/arm64/v8, arm64, linux).
--stigboolANCHORECTL_STIGfalseNoPerform a STIG evaluation on the image.
--stig-container-manual-overridestringANCHORECTL_STIG_CONTAINER_MANUAL_OVERRIDE""NoDocker container ID to use as the STIG target (skips creating container with anchore-keep-alive binary).
--stig-input-filestring (repeatable)ANCHORECTL_STIG_INPUT_FILE[]NoPath to input file to use for STIG generation (optional).
--stig-output-dirstringANCHORECTL_STIG_OUTPUT_DIR""NoPath to save the STIG evaluation (optional).
--stig-profilestringANCHORECTL_STIG_PROFILE""NoPath to STIG profile (required when --stig is set).
--stig-tools-binary-pathstringANCHORECTL_STIG_TOOLS_BINARY_PATH""NoPath to the statically-linked busybox binary inside the tools image (default: /bin/busybox).
--stig-tools-imagestringANCHORECTL_STIG_TOOLS_IMAGE""NoContainer image containing a statically-linked busybox binary for shell-less image support (e.g. docker.io/library/busybox:musl). The binary must be statically linked to work in distroless containers.
--stig-waiver-filestring (repeatable)ANCHORECTL_STIG_WAIVER_FILE[]NoPath to waiver file to use for STIG generation. The waiver file can waive controls and dictate the running and/or reporting of those controls (optional).
-w, --waitboolANCHORECTL_IMAGE_WAITfalseNoWait for the analysis to complete.

image ancestors

List analyzed ancestor images, which are the images that form the base layers of the image.

anchorectl image ancestors IMAGE [flags]

Aliases: ancestor

Arguments

ArgumentDescription
IMAGEThe image to fetch the ancestors for (can be a digest, id, or registry/repo:tag).

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-b, --baseboolANCHORECTL_ANCESTOR_BASEfalseNoOnly show the analyzed ancestor image with the fewest layers.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, id. See Output Formats.
-p, --parentboolANCHORECTL_ANCESTOR_PARENTfalseNoOnly show the analyzed ancestor image with the most layers.

image check

Get the policy evaluation for the given image.

anchorectl image check IMAGE [flags]

Aliases: evaluate

Arguments

ArgumentDescription
IMAGEThe image to fetch the policy evaluation for (can be a digest, id or registry/repo:tag). If supplying a digest or image id, a tag must be supplied with the -t flag.

Examples

# Evaluate the active policy against an image
anchorectl image check registry.example.com/my-service:1.4.0

# Show every failing gate, and exit 1 when the evaluation result is fail
anchorectl image check registry.example.com/my-service:1.4.0 --detail --fail-based-on-results

# Evaluate against a specific policy instead of the active one
anchorectl image check registry.example.com/my-service:1.4.0 --policy strict-policy

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--base-digeststringANCHORECTL_IMAGE_CHECK_BASE_DIGESTautoNoBase image digest to compare against so findings report inherited_from_base; auto resolves the base image automatically, empty disables the comparison.
--detailboolANCHORECTL_IMAGE_CHECK_DETAILfalseNoShow each failed gate within the policy evaluation report.
-f, --fail-based-on-resultsboolANCHORECTL_FAIL_BASED_ON_RESULTSfalseNoSet the return code to 1 if the policy evaluation result shows as fail.
--historyboolANCHORECTL_IMAGE_CHECK_HISTORYfalseNoShow all previous policy evaluations.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results (HTML available with --detail). Allowable values: text, json, json-raw, id, csv, html. See Output Formats.
-d, --output-directorystringANCHORECTL_OUTPUT_DIRECTORY""NoOptional output directory to write results to.
-p, --policystringANCHORECTL_POLICY""NoThe policy name or ID to evaluate against (if not provided the default policy is used).
-t, --tagstringANCHORECTL_IMAGE_TAG""NoSpecify which tag (repo:tag) is evaluated for a given image ID or Image digest.

image content

Get image content.

anchorectl image content IMAGE [flags]

Aliases: contents

Arguments

ArgumentDescription
IMAGEThe image ID, digest, or name:tag to fetch content of.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-a, --available-typesboolANCHORECTL_AVAILABLE_TYPESfalseNoOnly show available content types and exit.
--filestringANCHORECTL_FILE""NoA file path to write a .tar file containing all retrieved files.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--overwriteboolANCHORECTL_OVERWRITEfalseNoWrite over an existing file when saving retrieved files tarball.
-t, --typestring (repeatable)ANCHORECTL_CONTENT_TYPES[]NoFilter down results to one or more vulnerability types; use --available-types to see valid values (default: fetch all available types).

image delete

Delete an image analysis.

anchorectl image delete IMAGE... [flags]

Aliases: del

Arguments

ArgumentDescription
IMAGEOne or more images to delete (can be a digest, id or registry/repo:tag). If no tag supplied defaults to latest.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-a, --allboolfalseNoDelete all images.
-f, --forceboolANCHORECTL_IMAGE_DELETE_FORCEfalseNoForce deletion of image by cancelling any subscription/notification settings prior to image delete.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

image get

Get information about a single image.

anchorectl image get IMAGE [flags]

Arguments

ArgumentDescription
IMAGEThe image ID, name:tag, name@sha256:digest, name:tag@sha256:digest, or sha256:digest value.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-i, --digeststringANCHORECTL_IMAGE_DIGEST""NoThe image digest.
--historyboolANCHORECTL_IMAGE_HISTORYfalseNoShow history of images that match the input image.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

image list

List all images visible to the user.

anchorectl image list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-s, --analysis-statusstringANCHORECTL_IMAGE_ANALYSIS_STATUS""NoFilter by analysis_status value on the record. Allowable values: not_analyzed, analyzed, analyzing, analysis_failed.
--historyboolANCHORECTL_IMAGE_HISTORYfalseNoInclude full history of images (duplicate tags with previous content).
-i, --imagestringANCHORECTL_IMAGE_NAME""NoTag-based docker-pull string to filter results by (e.g. docker.io/library/nginx:latest, or myhost.com:5000/testimages:v1.1.1).
--image-statusstringANCHORECTL_IMAGE_STATUSactiveNoFilter by “image_status” value on the record. Allowable values: all, active, deleting.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

image metadata

Get image metadata.

anchorectl image metadata IMAGE [flags]

Arguments

ArgumentDescription
IMAGEThe image ID, digest, or name:tag to fetch metadata of.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--filestringANCHORECTL_FILE""NoA file path to write the metadata out to.
--overwriteboolANCHORECTL_OVERWRITEfalseNoWrite over existing metadata files.
-t, --typestringANCHORECTL_METADATA_TYPE""NoFilter down results to one or more vulnerability types (run command without this flag to see available types for the given image).

image one-time-scan

Analyze a container image.

anchorectl image one-time-scan IMAGE [flags]

Arguments

ArgumentDescription
IMAGEThe container image to analyze (e.g. docker.io/library/nginx:latest).

Examples

anchorectl image one-time-scan ghcr.io/anchore/enterprise-test-images:latest

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--detailboolANCHORECTL_DETAILfalseNoShow policy evaluation details (always enabled for HTML output).
--dockerfilestringANCHORECTL_DOCKERFILE""NoPath to Dockerfile to use for analysis.
--extended-supportstringANCHORECTL_EXTENDED_SUPPORT""NoUse Extended Update Support (EUS) data during the vulnerability scan. Will use the system configured behaviour if not provided. Allowable values: true, false.
--fail-on-policy-errorboolANCHORECTL_FAIL_ON_POLICY_ERRORfalseNoFail if policy evaluation fails.
-o, --formatstringANCHORECTL_FORMATtextNoOutput format (text, JSON, json-raw, HTML).
--fromstringANCHORECTL_FROMregistryNoSource of the image to analyze (registry, docker, or podman) (docker and podman: if the image is not present in the daemon it is pulled from the registry).
-d, --output-directorystringANCHORECTL_OUTPUT_DIRECTORY""NoOptional output directory to write results to.
--platformstringANCHORECTL_PLATFORM""NoPlatform to use for analysis.
-p, --policystringANCHORECTL_POLICY""NoPolicy bundle (name or id) to use for evaluation.

image sbom

Get image SBOM in the native Anchore format.

anchorectl image sbom IMAGE [flags]

Arguments

ArgumentDescription
IMAGEThe image reference (ID, digest, name:tag).

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-x, --exclude-filesboolANCHORECTL_EXCLUDE_FILESfalseNoExclude files from the SBOM (this only valid for CycloneDX formats.
-f, --filestringANCHORECTL_FILE""NoWrite the SBOM content to a file (instead of STDOUT).
-o, --outputstringsyft-jsonNoReport output format, options: cyclonedx-json, cyclonedx-xml, purls, spdx-json, spdx-tag-value, syft-json, table, text. See Output Formats.
--overwriteboolANCHORECTL_OVERWRITEfalseNoWrite over existing SBOM files.

image vulnerabilities

Get image vulnerabilities.

anchorectl image vulnerabilities IMAGE [flags]

Aliases: vulns, vuln

Arguments

ArgumentDescription
IMAGEThe image ID, digest, or name:tag to fetch vulnerabilities for.

Examples

# All vulnerabilities for an image
anchorectl image vulnerabilities registry.example.com/my-service:1.4.0

# Only OS package findings the vendor has not marked as won't-fix
anchorectl image vulnerabilities registry.example.com/my-service:1.4.0 --type os --vendor-only

# Write JSON results to a directory. --output-directory accepts only
# json, json-raw, html, and csv
anchorectl image vulnerabilities registry.example.com/my-service:1.4.0 --output json --output-directory ./reports

# CycloneDX output requires an image digest, not a tag
anchorectl image vulnerabilities sha256:<DIGEST> --output cyclonedx-json

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--annotationsstring (repeatable)ANCHORECTL_VULNERABILITY_ANNOTATIONS[]NoFilter results to include only vulnerabilities with the given annotation status. Accepts a comma separated list of: not_affected, affected, fixed, under_investigation.
-a, --available-typesboolfalseNoOnly show available vulnerability types and exit.
--include-descriptionboolANCHORECTL_VULNERABILITY_INCLUDE_DESCRIPTIONfalseNoInclude full descriptions in the vulnerability result.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, csv, cyclonedx-json, cyclonedx-xml, html. See Output Formats.
-d, --output-directorystringANCHORECTL_OUTPUT_DIRECTORY""NoOptional output directory to write results to.
-r, --refreshboolANCHORECTL_VULNERABILITY_REFRESHfalseNoRefresh the vulnerability match results against the original artifact.
-t, --typestring (repeatable)ANCHORECTL_VULNERABILITY_TYPE[]NoFilter down results to one or more vulnerability types.
--vendor-onlyboolANCHORECTL_VULNERABILITY_VENDOR_ONLYfalseNoFilter results to include only vulnerabilities that are not marked as invalid by upstream OS vendor data. When set to true, it will filter out all vulnerabilities where will_not_fix is False. If false all vulnerabilities are returned regardless of will_not_fix.

12 - anchorectl inventory

Inventory list operation.

Every command on this page also accepts the global flags.

Subcommands

inventory delete

Delete inventory from the system.

anchorectl inventory delete [flags]

Aliases: del

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--typestringANCHORECTL_INVENTORY_INVENTORY_TYPE""YesThe type of inventory to delete.
--contextstringANCHORECTL_CONTEXT""NoThe inventory context.
--image-digeststringANCHORECTL_IMAGE_DIGEST""NoThe image digest to delete inventory for.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
-y, --yesboolANCHORECTL_CONFIRMfalseNoConfirm the deletion of the inventory.

inventory list

Returns a list of the images that are in use.

anchorectl inventory list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--contextstringANCHORECTL_INVENTORY_CONTEXT""NoLimit results to a specific image context.
--image-digeststringANCHORECTL_INVENTORY_IMAGE_DIGEST""NoSearch for a specific image digest.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--typestringANCHORECTL_INVENTORY_TYPE""NoThe inventory type to limit results (e.g. Kubernetes).

inventory watch

Inventory subscription operations.

anchorectl inventory watch [command]

Subcommands

inventory watch activate

Watching a runtime inventory context will cause images to be automatically scheduled for analysis on discovery.

anchorectl inventory watch activate INVENTORY_CONTEXT [flags]

Arguments

ArgumentDescription
INVENTORY_CONTEXTInventory context.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

inventory watch deactivate

Runtime inventory context to stop watching.

anchorectl inventory watch deactivate INVENTORY_CONTEXT [flags]

Arguments

ArgumentDescription
INVENTORY_CONTEXTRuntime inventory context.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

inventory watch list

List all runtime inventory which have a watch configured.

anchorectl inventory watch list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-k, --keystringANCHORECTL_SUBSCRIPTION_KEY""NoFilter on this specific inventory context.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

13 - anchorectl policy

Policy related operations.

Every command on this page also accepts the global flags.

Subcommands

policy activate

Activate a policy.

anchorectl policy activate POLICY [flags]

Arguments

ArgumentDescription
POLICYThe policy name or ID.

Examples

anchorectl policy activate strict-policy

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

policy add

Adds a new policy bundle to the system.

anchorectl policy add [flags]

Examples

# Upload a policy bundle from a file
anchorectl policy add --input strict-policy.json

# Upload a policy bundle from stdin
cat strict-policy.json | anchorectl policy add --input -

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-i, --inputstringANCHORECTL_INPUT""YesPath to a JSON input file or - to read from stdin.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

policy delete

Delete the specified policy.

anchorectl policy delete POLICY [flags]

Aliases: del

Arguments

ArgumentDescription
POLICYThe policy name or ID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

policy get

Get the policy content.

anchorectl policy get POLICY [flags]

Arguments

ArgumentDescription
POLICYThe policy name or ID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--detailboolANCHORECTL_POLICY_DETAILtrueNoInclude policy detail in the form of the full policy content.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

policy list

List all saved policies.

anchorectl policy list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--detailboolANCHORECTL_DETAILfalseNoInclude full policy content. Available with output selections of [JSON | json-raw].
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

policy update

Update/replace an existing policy.

anchorectl policy update [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-i, --inputstringANCHORECTL_INPUT""YesPath to a JSON input file or - to read from stdin.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

14 - anchorectl registry

Registry credential operations.

Every command on this page also accepts the global flags.

Subcommands

  • registry add — Adds a new registry to the system
  • registry delete — Delete a registry configuration record from the system. Does not remove any images.
  • registry get — Get information on a specific registry
  • registry list — List all configured registries the system can/will watch
  • registry update — Replaces an existing registry record with the given record

registry add

Adds a new registry to the system.

anchorectl registry add REGISTRY [flags]

Arguments

ArgumentDescription
REGISTRYHostname:port string for accessing the registry, as would be used in a docker pull operation. May include some or all of a repository and wildcards (e.g. docker.io/library/* or gcr.io/myproject/myrepository).

Examples

# The password is read from the environment, never passed as a flag
ANCHORECTL_REGISTRY_PASSWORD=<REGISTRY_PASSWORD> anchorectl registry add registry.example.com \
  --username ci-runner

# Verify the credential when the registry is added. If the registry cannot be
# reached with these credentials, the command exits 1 and no record is created
ANCHORECTL_REGISTRY_PASSWORD=<REGISTRY_PASSWORD> anchorectl registry add registry.example.com \
  --username ci-runner --validate

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--usernamestringANCHORECTL_REGISTRY_USERNAME""YesUsername portion of credential to use for this registry.
--namestringANCHORECTL_REGISTRY_NAME""NoHuman readable name associated with registry record.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--secure-connectionboolANCHORECTL_REGISTRY_SECURE_CONNECTIONtrueNoUse TLS/SSL verification for the registry URL.
--typestringANCHORECTL_REGISTRY_TYPEdocker_v2NoType of registry.
--validateboolANCHORECTL_REGISTRY_VALIDATEtrueNoWhether or not to validate registry/credential at registry add time.

registry delete

Delete a registry configuration record from the system. Does not remove any images.

anchorectl registry delete REGISTRY [flags]

Aliases: del

Arguments

ArgumentDescription
REGISTRYThe registry name.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

registry get

Get information on a specific registry.

anchorectl registry get REGISTRY [flags]

Arguments

ArgumentDescription
REGISTRYRegistry name.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

registry list

List all configured registries the system can/will watch.

anchorectl registry list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

registry update

Replaces an existing registry record with the given record.

anchorectl registry update REGISTRY [flags]

Arguments

ArgumentDescription
REGISTRYThe registry name.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--namestringANCHORECTL_REGISTRY_NAME""NoHuman readable name associated with registry record.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--secure-connectionboolANCHORECTL_REGISTRY_SECURE_CONNECTIONfalseNoUse TLS/SSL verification for the registry URL.
--typestringANCHORECTL_REGISTRY_TYPE""NoType of registry.
--usernamestringANCHORECTL_REGISTRY_USERNAME""NoUsername portion of credential to use for this registry.
--validateboolANCHORECTL_REGISTRY_VALIDATEtrueNoWhether or not to validate registry/credential at registry update time.

15 - anchorectl repo

Repository related operations.

Every command on this page also accepts the global flags.

Subcommands

repo add

Add repository to watch.

anchorectl repo add REPOSITORY [flags]

Arguments

ArgumentDescription
REPOSITORYFull repository to add e.g. docker.io/library/alpine.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--auto-subscribeboolANCHORECTL_REPO_AUTO_SUBSCRIBEfalseNoEnable/disable auto tag_update activation when new images from a repo are added.
--dry-runboolANCHORECTL_REPO_DRY_RUNfalseNoReturn tags in the repository without actually watching the repository.
--exclude-existing-tagsboolANCHORECTL_REPO_EXCLUDE_EXISTING_TAGSfalseNoIndicates if you want to ignore the existing tags in the repository on the first execution.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

repo delete

Delete a repository subscription.

anchorectl repo delete REPOSITORY [flags]

Aliases: del

Arguments

ArgumentDescription
REPOSITORYFull repository e.g. docker.io/library/alpine.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

repo get

Get a specific repository subscription.

anchorectl repo get REPOSITORY [flags]

Arguments

ArgumentDescription
REPOSITORYFull repository e.g. docker.io/library/alpine.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

repo list

List all repository subscriptions.

anchorectl repo list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--repositorystringANCHORECTL_REPOSITORY_NAME""NoFilter only subscriptions matching the repository.

repo unwatch

Stop watching a specific repository.

anchorectl repo unwatch REPOSITORY [flags]

Arguments

ArgumentDescription
REPOSITORYFull repository e.g. docker.io/library/alpine.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

repo watch

Start watching a specific repository.

anchorectl repo watch REPOSITORY [flags]

Arguments

ArgumentDescription
REPOSITORYFull repository e.g. docker.io/library/alpine.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

16 - anchorectl stig

STIG related operations.

Every command on this page also accepts the global flags.

Subcommands

stig docker

Docker related STIG operations.

anchorectl stig docker [command]

Subcommands

stig docker image

Docker image related STIG operations.

anchorectl stig docker image [command]

Subcommands

stig docker image add

Add a STIG evaluation for an image.

anchorectl stig docker image add IMAGE STIG_EVALUATION_FILE [flags]

Arguments

ArgumentDescription
IMAGEThe image ID, name:tag, name@sha256:digest, name:tag@sha256:digest, or sha256:digest value.
STIG_EVALUATION_FILEThe path and filename for the STIG evaluation file.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
--stig-evaluation-uuidstringANCHORECTL_STIG_EVALUATION_UUID""NoThe UUID for the STIG evaluation to overwrite, if the image already has a STIG evaluation for the same profile this must be provided to upload the new evaluation.

stig docker image delete

Delete a STIG evaluation for an image.

anchorectl stig docker image delete IMAGE EVALUATION_UUID [flags]

Aliases: del

Arguments

ArgumentDescription
EVALUATION_UUIDThe UUID of the STIG evaluation.
IMAGEThe image ID, name:tag, name@sha256:digest, name:tag@sha256:digest, or sha256:digest value.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

stig docker image download

Download a STIG evaluation for an image.

anchorectl stig docker image download IMAGE EVALUATION_UUID [flags]

Arguments

ArgumentDescription
EVALUATION_UUIDThe UUID of the STIG evaluation.
IMAGEThe image ID, name:tag, name@sha256:digest, name:tag@sha256:digest, or sha256:digest value.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--stig-output-dirstringANCHORECTL_STIG_OUTPUT_DIR""NoDirectory to save the STIG evaluation.

stig docker image execute

Perform a STIG evaluation generation for an image.

anchorectl stig docker image execute IMAGE [flags]

Arguments

ArgumentDescription
IMAGEFully qualified image reference in format [registry/]repository/image:tag@digest.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-p, --stig-profilestringANCHORECTL_STIG_PROFILE""YesPath to the Inspec STIG profile, can be a folder containing the extracted profile or an archive e.g. .tar.gz (required).
--platformstringANCHORECTL_PLATFORM""NoAn optional platform specifier used when pulling the image into the docker daemon (e.g. linux/arm64, linux/amd64). Set this when the daemon cannot select an entry from a multi-arch image index on its own (optional).
--stig-container-manual-overridestringANCHORECTL_STIG_CONTAINER_MANUAL_OVERRIDE""NoDocker container ID to use as the STIG target (skips creating container with anchore-keep-alive binary).
-i, --stig-input-filestring (repeatable)ANCHORECTL_STIG_INPUT_FILE[]NoPath to input file to use for STIG generation. The input file can optionally provide variable inputs to the STIG profile that can change the execution of specific controls (optional).
--stig-output-dirstringANCHORECTL_STIG_OUTPUT_DIR""NoPath to save the STIG evaluation (optional).
--stig-skip-uploadboolANCHORECTL_STIG_SKIP_UPLOADfalseNoSkip uploading the STIG evaluation to Anchore (optional).
--stig-tools-binary-pathstringANCHORECTL_STIG_TOOLS_BINARY_PATH""NoPath to the statically-linked busybox binary inside the tools image (default: /bin/busybox).
--stig-tools-imagestringANCHORECTL_STIG_TOOLS_IMAGE""NoContainer image containing a statically-linked busybox binary for shell-less image support (e.g. docker.io/library/busybox:musl). The binary must be statically linked to work in distroless containers.
--stig-waiver-filestring (repeatable)ANCHORECTL_STIG_WAIVER_FILE[]NoPath to waiver file to use for STIG generation. The waiver file can waive controls and dictate the running and/or reporting of those controls (optional).

stig docker image list

List the STIG evaluation metadata for an image.

anchorectl stig docker image list IMAGE [flags]

Arguments

ArgumentDescription
IMAGEThe image ID, name:tag, name@sha256:digest, name:tag@sha256:digest, or sha256:digest value.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

stig write-profiles

Write Anchore STIG profiles to disk.

anchorectl stig write-profiles PATH [flags]

Arguments

ArgumentDescription
PATHPath to write the profiles to.

17 - anchorectl subscription

Subscription related operations.

Every command on this page also accepts the global flags.

Subcommands

subscription activate

Activate an existing subscription.

anchorectl subscription activate KEY TYPE [flags]

Arguments

ArgumentDescription
KEYThe subscription key.
TYPEThe type of the subscription (e.g. tag_update, policy_eval, vuln_update, analysis_update, runtime_inventory).

Examples

anchorectl subscription activate registry.example.com/my-service:1.4.0 tag_update

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

subscription deactivate

Deactivate an existing subscription.

anchorectl subscription deactivate KEY TYPE [flags]

Arguments

ArgumentDescription
KEYThe subscription key.
TYPEThe type of the subscription (e.g. tag_update, policy_eval, vuln_update, analysis_update, runtime_inventory).

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

subscription delete

Delete a subscription.

anchorectl subscription delete KEY TYPE [flags]

Aliases: del

Arguments

ArgumentDescription
KEYThe subscription key.
TYPEThe type of the subscription (e.g. tag_update, policy_eval, vuln_update, analysis_update).

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

subscription get

Get a specific subscription.

anchorectl subscription get KEY TYPE [flags]

Arguments

ArgumentDescription
KEYThe subscription key.
TYPEThe type of the subscription (e.g. tag_update, policy_eval, vuln_update, analysis_update).

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

subscription list

List all subscriptions.

anchorectl subscription list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-k, --keystringANCHORECTL_SUBSCRIPTION_KEY""NoFilter only subscriptions matching key.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
-t, --typestringANCHORECTL_SUBSCRIPTION_TYPE""NoFilter only subscriptions matching type.

18 - anchorectl system

System related operations.

Every command on this page also accepts the global flags.

Subcommands

system artifact-lifecycle-policy

Global artifact lifecycle policy operations.

anchorectl system artifact-lifecycle-policy [command]

Subcommands

system artifact-lifecycle-policy add

Creates an artifact lifecycle policy.

anchorectl system artifact-lifecycle-policy add [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--actionstring""YesThe artifact policy action. Allowable values: delete.
--artifact-typestring""YesThe artifact type the policy will act on. Allowable values: image.
--days-since-analyzedstring""YesThe number of days elapsed since the artifact was analyzed for it to be selected for action.
--even-if-exists-in-runtimestring""YesWhen true, images matching all criteria and found in the runtime inventory can be selected for action. Allowable values: true, false.
--include-base-imagesstring""YesWhen true, images matching all criteria and with known children can be selected for action. Allowable values: true, false.
--include-failed-analysisstring""YesWhen true, images matching all criteria and in a failed analysis state can be selected for action. Allowable values: true, false.
--namestring""YesA unique name for the artifact policy.
--descriptionstring""NoA description for the policy.
--enablestringfalseNoWhen true, the policy will be enabled. Allowable values: true, false.
-o, --outputstringtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

system artifact-lifecycle-policy delete

Delete artifact lifecycle policy.

anchorectl system artifact-lifecycle-policy delete POLICY_UUID [flags]

Aliases: del

Arguments

ArgumentDescription
POLICY_UUIDThe uuid of the artifact lifecycle policy.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

system artifact-lifecycle-policy get

Get single artifact lifecycle policy with latest conditions.

anchorectl system artifact-lifecycle-policy get POLICY_UUID [flags]

Arguments

ArgumentDescription
POLICY_UUIDThe uuid of the artifact lifecycle policy.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

system artifact-lifecycle-policy list

List all artifact lifecycle policies.

anchorectl system artifact-lifecycle-policy list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

system artifact-lifecycle-policy update

Updates an artifact lifecycle policy.

anchorectl system artifact-lifecycle-policy update POLICY_UUID [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--actionstring""YesThe artifact policy action. Allowable values: delete.
--artifact-typestring""YesThe artifact type the policy will act on. Allowable values: image.
--days-since-analyzedstring""YesThe number of days elapsed since the artifact was analyzed for it to be selected for action.
--enablestring""YesWhen true, the policy will be enabled. Allowable values: true, false.
--even-if-exists-in-runtimestring""YesWhen true, images matching all criteria and found in the runtime inventory can be selected for action. Allowable values: true, false.
--include-base-imagesstring""YesWhen true, images matching all criteria and with known children can be selected for action. Allowable values: true, false.
--include-failed-analysisstring""YesWhen true, images matching all criteria and in a failed analysis state can be selected for action. Allowable values: true, false.
--namestring""YesA unique name for the artifact policy.
--descriptionstring""NoA description for the policy.
-o, --outputstringtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

system delete

Delete service.

anchorectl system delete SERVICE_NAME HOST_ID [flags]

Aliases: del

Arguments

ArgumentDescription
SERVICE_NAMEThe service to delete, as shown in the SERVICE column of anchorectl system status.
HOST_IDThe host ID of the service instance, as shown in the HOST ID column of anchorectl system status.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

system integration

Product Integration Operations.

anchorectl system integration [command]

Subcommands

system integration delete

Delete the health data for an integration instance.

anchorectl system integration delete INTEGRATION_UUID [flags]

Aliases: del

Arguments

ArgumentDescription
INTEGRATION_UUIDThe integration UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--forceboolANCHORECTL_FORCEfalseNoForce deletion of the integration instance regardless of its state.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

system integration get

Get information about an integration instance.

anchorectl system integration get INTEGRATION [flags]

Arguments

ArgumentDescription
INTEGRATIONThe integration UUID.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

system integration list

Lists all integrations that have been created (explicitly or indirectly via registration).

anchorectl system integration list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

system role

RBAC Role Operations.

anchorectl system role [command]

Subcommands

system role get

Get detailed information about a specific role.

anchorectl system role get ROLE_NAME [flags]

Arguments

ArgumentDescription
ROLE_NAMEName of the RBAC Role.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

system role list

List roles available in the system.

anchorectl system role list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

system smoke-tests

Smoke test related operations.

anchorectl system smoke-tests [command]

Subcommands

system smoke-tests run

Run smoke tests.

anchorectl system smoke-tests run [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-i, --imagestring""NoThe image to run the smoke tests against.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

system status

Get the system status.

anchorectl system status [flags]

Examples

anchorectl system status

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

system wait

Wait for configured Anchore system to be running based upon set of filters.

anchorectl system wait [flags]

Examples

# Block until the API is up and feeds have synced, giving up after 5 minutes
anchorectl system wait --timeout 300

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-i, --intervalintANCHORECTL_SYSTEM_INTERVAL5NoInterval in which to query the system, in seconds. Default = 5.
--servicesstring (repeatable)ANCHORECTL_SYSTEM_SERVICES[apiext]NoService(s) to wait for. Options are [apiext,catalog,component_catalog,policy_engine,simplequeue,analyzer,notifications,reports,reports_worker].
-t, --timeoutintANCHORECTL_SYSTEM_TIMEOUT-1NoNumber of seconds to wait until error out. < 0 waits forever. Default = -1.
--wait-for-feedsboolANCHORECTL_SYSTEM_WAIT_FOR_FEEDStrueNoWait until feeds are synced. Defaults to true.

19 - anchorectl user

User related operations.

Every command on this page also accepts the global flags.

Subcommands

  • user add — Create a new user
  • user delete — Delete a specific user credential by username of the credential. Cannot be the credential used to authenticate the request.
  • user get — Get a specific user in the specified account
  • user list — List users for the account
  • user set-password — Set the password for a user

user add

Create a new user.

anchorectl user add USERNAME [flags]

Arguments

ArgumentDescription
USERNAMEThe name of the user to create.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--accountstringANCHORECTL_USER_ACCOUNT""NoThe account to use, defaults to current account.
--idp_namestringANCHORECTL_IDP_NAME""NoThe name of the IDP user will be authenticated with.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, id. See Output Formats.
--rolestring (repeatable)ANCHORECTL_USER_ROLE[]NoThe initial role(s) for the user. Defaults to (read-write) when not in the admin account.

user delete

Delete a specific user credential by username of the credential. Cannot be the credential used to authenticate the request.

anchorectl user delete USERNAME [flags]

Aliases: del

Arguments

ArgumentDescription
USERNAMEName of the user to delete.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--accountstringANCHORECTL_USER_ACCOUNT""NoThe account to use, defaults to current account.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

user get

Get a specific user in the specified account.

anchorectl user get USERNAME [flags]

Arguments

ArgumentDescription
USERNAMEName of the user to fetch.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--accountstringANCHORECTL_USER_ACCOUNT""NoThe account to use, defaults to current account.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

user list

List users for the account.

anchorectl user list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--accountstringANCHORECTL_USER_ACCOUNT""NoThe account to use, defaults to current account.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

user set-password

Set the password for a user.

anchorectl user set-password USERNAME [flags]

Arguments

ArgumentDescription
USERNAMEName of the user to set the password for.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
--accountstringANCHORECTL_USER_ACCOUNT""NoThe account to use, defaults to the current account.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

20 - anchorectl usergroup

User Group Management Operations.

Every command on this page also accepts the global flags.

Subcommands

usergroup add

Create a new user group.

anchorectl usergroup add NAME [flags]

Arguments

ArgumentDescription
NAMEThe name of the user group.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-d, --descriptionstringANCHORECTL_USERGROUPPOST_DESCRIPTION""NoThe description of the user group.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

usergroup delete

Delete a user group.

anchorectl usergroup delete USER_GROUP [flags]

Aliases: del

Arguments

ArgumentDescription
USER_GROUPThe name or uuid of the user group.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

usergroup get

Get a user group.

anchorectl usergroup get USER_GROUP [flags]

Arguments

ArgumentDescription
USER_GROUPThe name or uuid of the user group.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

usergroup list

List user groups.

anchorectl usergroup list [flags]

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-a, --contains-accountstringANCHORECTL_USERGROUP_CONTAINS_ACCOUNT""NoFilter the user groups to only those that contain the specified domain name.
-u, --contains-userstringANCHORECTL_USERGROUP_CONTAINS_USER""NoFilter the user groups to only those that contain the specified user.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
-g, --user-group-namestringANCHORECTL_USERGROUP_USER_GROUP_NAME""NoFilter results to match the specified user group name.

usergroup role

User Group Role Operations.

anchorectl usergroup role [command]

Subcommands

usergroup role add

Add domain name and role(s) to this user group.

anchorectl usergroup role add USER_GROUP DOMAIN_NAME [flags]

Arguments

ArgumentDescription
DOMAIN_NAMEThe domain name.
USER_GROUPThe name or uuid of the user group.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-i, --inputstringANCHORECTL_INPUT""NoPath to a JSON input file or - to read from stdin.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
-r, --rolestring (repeatable)ANCHORECTL_ROLE[]NoThe RBAC role(s) that will be associated with the specified domain.

usergroup role delete

Remove domain name and role(s) from this user group.

anchorectl usergroup role delete USER_GROUP DOMAIN_NAME [flags]

Aliases: del

Arguments

ArgumentDescription
DOMAIN_NAMEThe domain name.
USER_GROUPThe name or uuid of the user group.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
-r, --rolestring (repeatable)ANCHORECTL_ROLE[]NoThe RBAC role(s) that will be associated with the specified domain name.

usergroup role list

List accounts and roles configured in this user group.

anchorectl usergroup role list USER_GROUP [flags]

Arguments

ArgumentDescription
USER_GROUPThe name or uuid of the user group.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-i, --inputstringANCHORECTL_INPUT""NoPath to a JSON input file or - to read from stdin.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

usergroup update

Update a user group.

anchorectl usergroup update USER_GROUP [flags]

Arguments

ArgumentDescription
USER_GROUPThe name or uuid of the user group.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-d, --descriptionstringANCHORECTL_USERGROUP_DESCRIPTION""YesThe description of the user group.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

usergroup user

User Group User Operations.

anchorectl usergroup user [command]

Subcommands

usergroup user add

Add user(s) to this user group.

anchorectl usergroup user add USER_GROUP [flags]

Arguments

ArgumentDescription
USER_GROUPThe name or uuid of the user group.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-i, --inputstringANCHORECTL_INPUT""NoPath to a JSON input file or - to read from stdin.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
-u, --userstring (repeatable)ANCHORECTL_USER[]NoThe username(s) that will be associated with the User Group.

usergroup user delete

Remove user(s) from this user group.

anchorectl usergroup user delete USER_GROUP [flags]

Aliases: del

Arguments

ArgumentDescription
USER_GROUPThe name or uuid of the user group.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.
-u, --userstring (repeatable)ANCHORECTL_USER[]NoThe username(s) that will be removed from the User group.

usergroup user list

List users configured in this user group.

anchorectl usergroup user list USER_GROUP [flags]

Arguments

ArgumentDescription
USER_GROUPThe name or uuid of the user group.

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-i, --inputstringANCHORECTL_INPUT""NoPath to a JSON input file or - to read from stdin.
-o, --outputstringANCHORECTL_FORMATtextNoThe format to show the results. Allowable values: text, json, json-raw, id. See Output Formats.

21 - anchorectl version

Show anchorectl version information.

Every command on this page also accepts the global flags.

anchorectl version [flags]

Examples

# Print just the version string; works only as a root flag
anchorectl --version

# Full build detail: Syft version, build date, commit, and platform
anchorectl version

# Machine-readable. ANCHORECTL_FORMAT is ignored here, so pass the flag explicitly
anchorectl version --output json

Flags

FlagTypeEnvironment variableDefaultRequiredDescription
-o, --outputstringtextNoThe format to show the results. Allowable values: text, json. See Output Formats.