mirror of
https://gitee.com/ctexthuang/hyperf_rbac_framework_server_ctexthuang.git
synced 2025-12-25 21:37:50 +08:00
24 lines
738 B
PHP
24 lines
738 B
PHP
<?php
|
|
|
|
namespace App\Common\Interface;
|
|
|
|
use Lcobucci\JWT\UnencryptedToken;
|
|
|
|
interface JwtInterface
|
|
{
|
|
public function builderAccessToken(string $sub, ?\Closure $callable = null): UnencryptedToken;
|
|
|
|
public function builderRefreshToken(string $sub, ?\Closure $callable = null): UnencryptedToken;
|
|
|
|
public function parserAccessToken(string $accessToken): UnencryptedToken;
|
|
|
|
public function parserRefreshToken(string $refreshToken): UnencryptedToken;
|
|
|
|
public function addBlackList(UnencryptedToken $token): bool;
|
|
|
|
public function hasBlackList(UnencryptedToken $token): bool;
|
|
|
|
public function removeBlackList(UnencryptedToken $token): bool;
|
|
|
|
public function getConfig(string $key, mixed $default = null): mixed;
|
|
} |