sterntours/trunk/_vendor/sensiolabs/security-checker
Kevin Adametz 33458b2ca3 Update
2020-03-07 19:46:02 +01:00
..
SensioLabs/Security Update 2020-03-07 19:46:02 +01:00
.gitignore Update 2020-03-07 19:46:02 +01:00
box.json Update 2020-03-07 19:46:02 +01:00
composer.json Update 2020-03-07 19:46:02 +01:00
LICENSE Update 2020-03-07 19:46:02 +01:00
README.md Update 2020-03-07 19:46:02 +01:00
security-checker Update 2020-03-07 19:46:02 +01:00

SensioLabs Security Checker

The SensioLabs Security Checker is a command line tool that checks if your application uses dependencies with known security vulnerabilities. It uses the Security Check Web service and the Security Advisories Database.

Usage

Download the security-checker.phar file:

$ php security-checker.phar security:check /path/to/composer.lock

Use the code from the repository directly:

$ composer install
$ php security-checker security:check /path/to/composer.lock

Integration

The checker uses the Symfony Console component; so, you can easily integrate the checker into your own project:

  • by using the SecurityCheckerCommand class into your Symfony Console application;

  • by using the SecurityChecker class directly into your own code:

     use SensioLabs\Security\SecurityChecker;
    
     $checker = new SecurityChecker();
     $result = $checker->check('/path/to/composer.lock', 'json');
     $alerts = json_decode((string) $result, true);