You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to setup several authentication schemes with different handlers in such a way, that the handlers are called sequentially (order doesn't matter), but only if the previous one returns AuthenticateResult.NoResult() (that is, it did not handle the authentication). This is to support several alternative authentication schemes.
then the handlers would be called sequentially, because the default policy uses the specified schemes. However there is no difference whether I return AuthenticateResult.NoResult() or AuthenticateResult.Fail(), all authentication handlers are called. From what I was able to read, for example, here: #38685, then there is a situation in which NoResult can be used in such a way as I would expect it to.
So to sum up: is there a way to stop processing authentication handlers after one is able to return either Fail or Success, or do they all need to processed?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi
I would like to setup several authentication schemes with different handlers in such a way, that the handlers are called sequentially (order doesn't matter), but only if the previous one returns
AuthenticateResult.NoResult()
(that is, it did not handle the authentication). This is to support several alternative authentication schemes.From my understanding, if I used this code:
then the handlers would be called sequentially, because the default policy uses the specified schemes. However there is no difference whether I return
AuthenticateResult.NoResult()
orAuthenticateResult.Fail()
, all authentication handlers are called. From what I was able to read, for example, here: #38685, then there is a situation in which NoResult can be used in such a way as I would expect it to.So to sum up: is there a way to stop processing authentication handlers after one is able to return either Fail or Success, or do they all need to processed?
Beta Was this translation helpful? Give feedback.
All reactions