Access Token prefix underscore in name
This commit is contained in:
@@ -29,7 +29,7 @@ class AuthService
|
||||
$token = new UserToken;
|
||||
|
||||
$token->setOwnedBy($user);
|
||||
$token->setToken(sprintf('%s_%s', $type->value, hash(
|
||||
$token->setToken(sprintf('%s%s', $type->value, hash(
|
||||
self::TOKEN_HASH_ALGO,
|
||||
join('', [
|
||||
microtime(true),
|
||||
|
||||
@@ -6,13 +6,13 @@ enum AuthTokenType: string
|
||||
{
|
||||
/**
|
||||
* An OAuth type represents an Authentication Token created via an OAuth flow.
|
||||
* OAuth Tokens represent 3rd party apps acting on behalf of a User.
|
||||
* OAuth Access Tokens represent 3rd party apps acting on behalf of a User.
|
||||
*/
|
||||
case OAuth = 'oat';
|
||||
case OAuth = 'oat_';
|
||||
|
||||
/**
|
||||
* A Personal type represents an Authentication Token created via direct login.
|
||||
* Personal Access Tokens represent the User itself.
|
||||
*/
|
||||
case Personal = 'pat';
|
||||
case Personal = 'pat_';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user