Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker: Package script exit values #2648

Merged
merged 1 commit into from
May 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions site/content/docs/docker/api-scan.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,18 @@ Options:
--schema GraphQL schema location, URL or file, e.g. https://www.example.com/schema.graphqls
```

### Exit Value

The script will exit with codes of:
* 0: Success
* 1: At least 1 FAIL
* 2: At least one WARN and no FAILs
* 3: Any other failure

By default all alerts found by ZAP will be treated as WARNings.

You can use the `-c` or `-u` parameters to specify a configuration file to override this.

### Configuration
The configuration works in a very similar way as the [Baseline Scan](../baseline-scan/) so see the Baseline page for more details.

Expand Down
13 changes: 13 additions & 0 deletions site/content/docs/docker/baseline-scan.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,19 @@ WARN: X-Content-Type-Options Header Missing [10021] x 3
https://www.example.com/sitemap.xml
FAIL: 0 WARN: 4 IGNORE: 0 PASS: 22
```

### Exit Value

The script will exit with codes of:
* 0: Success
* 1: At least 1 FAIL
* 2: At least one WARN and no FAILs
* 3: Any other failure

By default all alerts found by ZAP will be treated as WARNings.

You can use the `-c` or `-u` parameters to specify a configuration file to override this.

### Configuration File
You can configure how the baseline scan runs with a configuration file. A default configuration file can be created using the '-g' parameter.
```
Expand Down
19 changes: 19 additions & 0 deletions site/content/docs/docker/full-scan.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,25 @@ docker run -v $(pwd):/zap/wrk/:rw -t ghcr.io/zaproxy/zaproxy:stable zap-full-sca
Note that `$(pwd)` is supported on Linux, MacOS and PowerShell.
See [Docker About - Mounting the current directory](/docs/docker/about/#mounting-the-current-directory) for Windows, etc.

### Exit Value

The script will exit with codes of:
* 0: Success
* 1: At least 1 FAIL
* 2: At least one WARN and no FAILs
* 3: Any other failure

By default all alerts found by ZAP will be treated as WARNings.

You can use the `-c` or `-u` parameters to specify a configuration file to override this.

### Configuration
The configuration works in a very similar way as the [Baseline Scan](../baseline-scan/) so see the Baseline page for more details.

### Configuration File
You can configure how the full scan runs with a configuration file. A default configuration file can be created using the '-g' parameter.
Unlike the baseline configuration file the full scan configuration file handles both active and passive scan rules.

### Scan Hooks
This script supports [scan hooks](../scan-hooks/) which allow you to override or modify behaviour of the script components instead of having to write a new script.

Expand Down