PHP Class Opis\Closure\DefaultSecurityProvider

Inheritance: implements Opis\Closure\SecurityProviderInterface
Mostra file Open project: opis/closure

Protected Properties

Property Type Description
$key Secret key

Public Methods

Method Description
__construct ( string $key ) Constructor
sign ( &$data ) : array Implementation of \Opis\Closure\SecurityProvider::sign
verify ( &$data ) : string | boolean Implementation of \Opis\Closure\SecurityProvider::verify

Method Details

__construct() public method

Constructor
public __construct ( string $key )
$key string Secret key

sign() public method

Implementation of \Opis\Closure\SecurityProvider::sign
public sign ( &$data ) : array
return array Secured data

verify() public method

Implementation of \Opis\Closure\SecurityProvider::verify
public verify ( &$data ) : string | boolean
return string | boolean Returns `false` if the signature is not valid

Property Details

$key protected_oe property

Secret key
protected $key