[Answer]-Django get Model by token

1👍

You don’t, that’s not how it works. The Django reset password view has two components: a base-64 encoded string of the user ID, and the token to check validity. Decoding the ID is as simple as calling base64.urlsafe_b64decode, but you can’t decode the token at all: it’s hashed and salted, the only thing you can do is create a new token with the user object and check that they match.

Leave a comment