how is @Authorize
meant to work?
#2789
Closed
VictoriqueMoe
started this conversation in
General
Replies: 1 comment
-
I solved this using |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have an issue.
It seems no matter what protocol is supplied into
@Authorize
, the route will ALWAYS work as long as there as active session, even if the suppplied protocol is not bound to sessions (say, basic.)given the following route:
and the following protocol:
If i have no active session. then it works as epected (asks for user/password).
However, lets say i have a cookie based login session using express-session:
and a protocol for session login:
and a login handler:
As soon as you login via the
/login
handler and a session is made. theshowBucketPage
route above will be called, and be authorised and will not call thebasic
protocl.this is an issue for applications that require multiple authentication protols.
How is
@Authorize
meant to work exactly, i assumeOnVerify
on the supplied protocol is not called for every single time the endpoint is hit. so how does the code know when to call the protocoll verify and whe not to when a route is decorated with@Authorize
?thanks,
VIctoria
Beta Was this translation helpful? Give feedback.
All reactions