Skip to content

dframe/token

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Dframe/Token - Component

Build Status Latest Stable Version Total Downloads Latest Unstable Version License

php framework dframe logo

Composer

$ composer require dframe/token

Standalone

use Dframe\Session\Session;
use Dframe\Token\Token;

$driver = new Session('sessionName');

/** 
 * $driver Can be any class implements interface \Psr\SimpleCache\CacheInterface 
 */
$token  = new Token($driver); 
$key = $token->generate('evidenceToken')->get('evidenceToken');  // Generate hash
$isValid = $token->isValid('evidenceToken', $key);            // Return true/false
$has = $token->has('evidenceToken');            // Return true/false

License

Open-sourced software licensed under the MIT license

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages