AuthenticateUser returns Unknown
Hi,
I am trying to authenticate the user from a web service request and then change its password. I can get the User but when I call AuthenticateUser with the correct password, it returns UserLoggingReason.Unknown.
UserManager userManager = UserManager.GetManager();
User user = userManager.GetUser(userName);
UserLoggingReason reason = SecurityManager.AuthenticateUser(UserManager.GetDefaultProviderName(), userName, password, false, out user);
To the best of my knowledge, the membership provider and forms authentication are set correctly and I am pointing to the correct database. Any insight would be appreciated.
Thanks,
Matt
Hi Matt,
Would it be possible to try switching to claims authentication and try again to test if you get the same result, please.
Atanas, thanks for responding. I just found out that this code works in another environment, so maybe there's a configuration problem. It looks like our other environment is set to forms authentication. I'll compare the two and see what I can find.