Skip to content
This repository has been archived by the owner on Dec 20, 2018. It is now read-only.

Usermanager.ResetPasswordAsync not working #680

Closed
lasrol opened this issue Dec 12, 2015 · 4 comments
Closed

Usermanager.ResetPasswordAsync not working #680

lasrol opened this issue Dec 12, 2015 · 4 comments
Assignees
Milestone

Comments

@lasrol
Copy link

lasrol commented Dec 12, 2015

I recently posted a question on stackoverflow, adding it here as well. Not sure if its a bug or if it is something i have done wrong.

Basicly when i call Usermanager.ResetpasswordAsync i get success, but when i try to login it fails.
Also it seem to be something wrong with the Password validation, i had to turn off all the

IdentityOptions.Password.Require*

Because it complained about not having Uppercase characters, even if it did.

More infor about the settings in this question http://stackoverflow.com/questions/34244367/identity-3-reset-password-unable-to-login

@rustd rustd added this to the 3.0.0-rc2 milestone Dec 14, 2015
@HaoK
Copy link
Member

HaoK commented Dec 15, 2015

From the stack overflow post it looks like you are mixing your own cookie options with identity. In RC1 the application cookie options are now part of IdentityOptions you should be setting them via: identityOptions.Cookies.ApplicationCookie

@lasrol
Copy link
Author

lasrol commented Dec 16, 2015

I get the stackoverflow post was a bit confusing, i did try several things to make it work. I have reproduced the issue in this repo https://github.com/lasrol/EmptyDB/

@HaoK HaoK reopened this Dec 16, 2015
@HaoK
Copy link
Member

HaoK commented Dec 16, 2015

So lets break this down into the exact issues.

  1. You are trying to reset the password and then log in with the new password? Can you try it explicitly via the user manager APIs to see if those are doing the right things. There are many reasons that could cause the app cookie to not be valid which would look like login failed.
  2. Same thing with the password validator, there are many things that could cause the update to fail on the user. Can you explicitly call the apis and see if they work for you, i.e. try ChangePassword and ResetPassword after manually generating a token inline right before calling the ResetPassword API

@lasrol
Copy link
Author

lasrol commented Dec 16, 2015

I am sorry, it was a big mistake on my part and i cannot belive i didn't see it! I was not passing in the correct variable to ResetPassword API. Sorry to take up your time.

@lasrol lasrol closed this as completed Dec 16, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants