c# - Identity Provider, MVC,override PasswordSignInAsync, custom storage provider - CRM -
actually l´m building website in mvc5, , l´m using .net identity. while connecting customstorageprovider(just usertable) crm, l´m lagged problem: when l trying logged in:
var result = await signinmanager.passwordsigninasync(model.email, model.password, model.rememberme, shouldlockout: false); // <-- here failure - different hashes + salt in crm switch (result) { ... }
passwordsigninasync logged user email , password, l´m using in crm different hashes , need edit behaviour of function, getting idea, how ? answers
create custom implementation of ipasswordhasher. public class mycustompasswordhasher : ipasswordhasher
and custom usermanager custom user class, if need: public class myacessousermanager : usermanager
so put setting on myacessousermanager this.passwordhasher = new mycustompasswordhasher();
see: http://aspnetguru.com/customize-authentication-to-your-own-set-of-tables-in-asp-net-mvc-5/
Comments
Post a Comment