Larry Martell
Larry Martell

Reputation: 3756

Django Microsoft Authentication Backend not succeeding on new deployments

I have an app deployed in many places and it uses Django Microsoft Authentication Backend. Starting yesterday when we deploy the app the auth is now not working. We get back Failed to authenticate you for an unknown reason. Please try again later. We can see in the azure logs that the login was successful. We have the same version of Django Microsoft Authentication Backend installed, but for some reason on newly built boxes it is failing but older ones it is succeeding. What could be causing this? What can we check to track down what the issue may be?

Upvotes: 2

Views: 529

Answers (2)

thespacecamel
thespacecamel

Reputation: 942

I was getting the same error after setting up a staging site based off the live site. The fix for me was clearing the rows from the database table microsoft_auth_microsoftaccount.

Upvotes: 0

Larry Martell
Larry Martell

Reputation: 3756

We finally found the issue - I said we had the same version of all the python packages but we did not - the new system had 2.0.1 version of pyjwt. When we downgraded to 1.7.1 it started working again. The requirements file for Django Microsoft Authentication Backend have pyjwt [required: Any]

Upvotes: 4

Related Questions