diff --git a/Security/Authenticator/Oauth2Authenticator.php b/Security/Authenticator/Oauth2Authenticator.php index 72ddf4ce..0b863537 100644 --- a/Security/Authenticator/Oauth2Authenticator.php +++ b/Security/Authenticator/Oauth2Authenticator.php @@ -14,7 +14,7 @@ namespace FOS\OAuthServerBundle\Security\Authenticator; use FOS\OAuthServerBundle\Model\AccessToken; -use FOS\OAuthServerBundle\Security\Authentication\Token\OAuthToken; +use FOS\OAuthServerBundle\Security\Authenticator\Token\OAuthToken; use FOS\OAuthServerBundle\Security\Authenticator\Passport\Badge\AccessTokenBadge; use OAuth2\OAuth2; use OAuth2\OAuth2AuthenticateException; diff --git a/Security/Authenticator/Token/OAuthToken.php b/Security/Authenticator/Token/OAuthToken.php new file mode 100644 index 00000000..eeac71a2 --- /dev/null +++ b/Security/Authenticator/Token/OAuthToken.php @@ -0,0 +1,41 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace FOS\OAuthServerBundle\Security\Authenticator\Token; + +use Symfony\Component\Security\Core\Authentication\Token\AbstractToken; + +/** + * OAuthToken class. + * + * @author Arnaud Le Blanc + */ +class OAuthToken extends AbstractToken +{ + protected string $token; + + public function setToken(string $token) + { + $this->token = $token; + } + + public function getToken(): string + { + return $this->token; + } + + public function getCredentials(): string + { + return $this->token; + } +} \ No newline at end of file