cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
294
Views
0
Helpful
1
Replies

Error exchanging code for 2fa token

Owlbear
Level 1
Level 1

I am trying to integrate the Web SDK v4, but receive the following error:

Error exchanging the code for a 2fa token

when trying to validate the code received from the redirect after authentication. The value in the redirected query string and the value printed to the logs of our app is the same. I don't understand why it's failing.

1 Reply 1

DuoKristina
Cisco Employee
Cisco Employee

There are a few reasons this could happen:
- make sure that the redirect_uri used matches in both the /oauth/v1/authorize and the /oauth/v1/token requests
- make sure your application/server can contact Duo's service for the token verification (the actual authentication happening in the Duo redirect happens in the client's browser)

Duo, not DUO.
Quick Links