Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Target class [Jose\Component\Signature\Algorithm\HS256] does not exist. #12

Closed
tommica opened this issue Jun 24, 2022 · 1 comment
Closed

Comments

@tommica
Copy link

tommica commented Jun 24, 2022

Just did a fresh Laravel install, and wanted to use LittleJWT in it, but when I am trying to generate a JWT with $jwt = Auth::buildJwtForUser($user); I get this error message:

Target class [Jose\Component\Signature\Algorithm\HS256] does not exist.

I could fix it by running sail composer require web-token/jwt-signature-algorithm-hmac:^2.1but I would imagine the package should handle this for me

@little-apps
Copy link
Owner

Thank you for filing this issue. The web-token/jwt-signature-algorithm-hmac package has been moved in the composer.json file so it's installed with both development and production installs. Developers wanting to use other JWT signature algorithms (ECDSA, RSA, etc.) will need to install the corresponding Composer package themselves (as mentioned in the JWK documentation).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants