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

[Authorize] appears to merely fake the response #42

Open
marius00 opened this issue Oct 15, 2022 · 0 comments
Open

[Authorize] appears to merely fake the response #42

marius00 opened this issue Oct 15, 2022 · 0 comments

Comments

@marius00
Copy link

marius00 commented Oct 15, 2022

Create a project following the steps in https://chillicream.com/docs/hotchocolate/v12/security/authentication and https://chillicream.com/docs/hotchocolate/v12/security/authorization

You'll now have a class with [Authorize], a basic query class which resolves on id/resolve all/whatever, and supposedly secured by a JWT token.

Performing a graphql to the endpoint without a JWT token (or an invalid one) will result in the error "The current user is not authorized to access this resource" as expected, but the endpoint is called, all the code is executed, only the response is altered.

No actual authentication/authorization checks are run at all before executing the code.
Only the response is faked to indicate that the query failed.

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

1 participant