django-trench icon indicating copy to clipboard operation
django-trench copied to clipboard

How / when is `/auth/code/request/` intended to be used?

Open SirWumpus opened this issue 3 years ago • 1 comments

Tried to use /auth/code/request/ for login. It is a protected route and needs to know the logged in user, so no good for resending login code.

Tried it for resending the activation code and it fails with {"detail":"Not found."}, because I think its trying to find the method that is not yet activated.

I'm confused by /auth/code/request/, because it doesn't appear to work for what I assumed was it purpose.

SirWumpus avatar Jun 11 '21 13:06 SirWumpus

I am likewise confused and trying to activate the method so that this endpoint can work. I am trying to add MFA to a user using /yubi/activate/ and it also cannot identify that the user is authenticated.

image

If I however go to /admin I can see the test user is authenticated:

image

Edit: Actually, it identifies authentication as long as I pass the correct Authentication header. But then I get a keyError originating from self.get_serializer_field_mapping()[klass] in trench/serializer.py

As for /auth/code/request/ I am stuck with the same {"detail":"Not found."} :(

image

Frikster avatar Nov 02 '21 19:11 Frikster

@SirWumpus To resend the activation code use again activation Url: https://django-trench.readthedocs.io/en/latest/endpoints.html#mfa-method-activation Endpoint to send the code: https://django-trench.readthedocs.io/en/latest/endpoints.html#send-the-code is used for the deactivation method or to generate new backup codes

wmaciejewskimer avatar Nov 22 '22 12:11 wmaciejewskimer

Closing since lack of response for 4 months.

wmaciejewskimer avatar Mar 13 '23 10:03 wmaciejewskimer

Given that when I posted the issue I needed an answer, 12+ months later get some reply. Business moved on, canned / boxed project. So ya. Close it. Code not viable.

SirWumpus avatar Mar 13 '23 11:03 SirWumpus