I have a custom class (with properties like UserID, UserName, UserEmail, etc) implementing IIdentity. I login through custom logic, which reads from sql. What should IIdentity's AuthenticationType return?
Implementing IIdentity, what is AuthenticationType?
Asked Answered
The best that I can gather is that AuthenticationType
is an arbitrary string that you can use in your app to determine the type of authentication that was used by a user.
For example, your app may offer a couple of different authentication mechanisms such as Passport and Custom, where Custom is something that you rolled yourself and decided to call it "Custom". Elsewhere in your app, you might have logic that needs to know how the user was authenticated, in which case you check the AuthenticationType
value against the name of your custom mechanism - "Custom".
can you provide any links, where you "gathered"? –
Magyar
Even years later, this would be a great snippet for them to include in the remarks of this property. –
Exacting
© 2022 - 2024 — McMap. All rights reserved.