You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, do you have any idea how could I differeniate the case when the user provides invalid credentials and the case when the user provides valid credentials but the user is disabled (is_active is False)? They both return 'Invalid credentials given.' message (which comes from oauthlib) but it would be important to differentiate the two cases. Currently it seems that a lot of functionality need to be overriden with a lot of duplicate codes to achieve it.
I'm open to any idea in general about how to handle this properly.
The text was updated successfully, but these errors were encountered:
same thought that I had when we moved from django-oauth2-provider (deprecated) to django-oauth-toolkit.
We use using DRF and we had to remove djangorestframework-oauth too.
Our workaround is to stuff a custom class with the missing logic copying from the removed package djangoframework-oauth package and then use this class as our oauth2 auth check and token retrieval.
But this solutions smells, so I'm open to other suggestions.
IMHO django-oauth-toolkit should implement the missing logic.
Our workaround is to stuff a custom class with the missing logic copying from the removed package djangoframework-oauth package and then use this class as our oauth2 auth check and token retrieval.
Hi, do you have any idea how could I differeniate the case when the user provides invalid credentials and the case when the user provides valid credentials but the user is disabled (is_active is False)? They both return 'Invalid credentials given.' message (which comes from oauthlib) but it would be important to differentiate the two cases. Currently it seems that a lot of functionality need to be overriden with a lot of duplicate codes to achieve it.
I'm open to any idea in general about how to handle this properly.
The text was updated successfully, but these errors were encountered: