Update docs for `audit` command (#12220)
parent
74f68adeb1
commit
666dc93fcc
|
@ -1068,13 +1068,18 @@ php composer.phar archive vendor/package 2.0.21 --format=zip
|
||||||
|
|
||||||
## audit
|
## audit
|
||||||
|
|
||||||
This command is used to audit the packages you have installed
|
This command is used to audit the packages you have installed for potential security issues. It checks for and lists security
|
||||||
for potential security issues. It checks for and
|
vulnerability advisories using the [Packagist.org api](https://packagist.org/apidoc#list-security-advisories) by default
|
||||||
lists security vulnerability advisories using the
|
or other repositories if specified in the `repositories` section of `composer.json`.
|
||||||
[Packagist.org api](https://packagist.org/apidoc#list-security-advisories)
|
The command also detects abandoned packages.
|
||||||
by default or other repositories if specified in the `repositories` section of `composer.json`.
|
|
||||||
|
|
||||||
The audit command returns the amount of vulnerabilities found. `0` if successful, and up to `255` otherwise.
|
The audit command determines if there are vulnerable or abandoned packages and returns the following exit codes based on
|
||||||
|
the findings:
|
||||||
|
|
||||||
|
* `0` No issues;
|
||||||
|
* `1` Vulnerable packages;
|
||||||
|
* `2` Abandoned packages;
|
||||||
|
* `3` Vulnerable and abandoned packages.
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
php composer.phar audit
|
php composer.phar audit
|
||||||
|
|
Loading…
Reference in New Issue