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

How to handle RequestDenied responses correctly? #50

Open
Restingo opened this issue Nov 29, 2022 · 0 comments
Open

How to handle RequestDenied responses correctly? #50

Restingo opened this issue Nov 29, 2022 · 0 comments

Comments

@Restingo
Copy link

Currently if I'm trying to sign in a user that has no permission to the application signing in to, if got an error 500:

[2022-11-29 13:57:14] staging.ERROR: saml2.error_detail {"error":"The status code of the Response was not Success, was Responder -> urn:oasis:names:tc:SAML:2.0:status:RequestDenied"}
[2022-11-29 13:57:14] staging.ERROR: saml2.error ["invalid_response"]
[2022-11-29 13:57:14] staging.ERROR: Symfony\Component\HttpFoundation\Response::setContent(): Argument #1 ($content) must be of type ?string, Illuminate\Routing\Redirector given, called in .../vendor/laravel/framework/src/Illuminate/Http/Response.php on line 72 {"exception":"[object] (TypeError(code: 0): Symfony\\Component\\HttpFoundation\\Response::setContent(): Argument #1 ($content) must be of type ?string, Illuminate\\Routing\\Redirector given, called in .../vendor/laravel/framework/src/Illuminate/Http/Response.php on line 72 at .../vendor/symfony/http-foundation/Response.php:412)

I am handling the login of the user in an Event listener. Where can I catch the exception and handle it correctly?

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