Shareplum: Authentication error [AADSTS50126]

927 Views Asked by At

recently I have been facing authentication issues with Shareplum library (to be precise it's since Friday 4th November 2022)

The following is my code:

from shareplum import Site
from shareplum import Office365    
from shareplum.site import Version

website = "https://xxxxxx.sharepoint.com"    
List_Name = 'Start'

sharepointUsername = "xxxxxxxxxx"    
sharepointPassword = "xxxxxxxxxx" 

authcookie = Office365(website, username=sharepointUsername,   
password=sharepointPassword).GetCookies()

site = Site(sharepointSite, version=Version.v2016, authcookie=authcookie)

The code was working well until last Thursday 3rd November 2022; no changes or modification was made to the code. There's no MFA enabled it's a single point authentication, I have seen that Shareplum has problem with MFA but I don't have that enabled and still this error persists.

Now I'm stuck with this error:

Exception: ('Error authenticating against Office 365. Error from Office 365:', 'AADSTS50126: Error validating credentials due to invalid username or password.')

can someone please help me out on tackling this problem?

error authenticating against Office 365. Error from Office 365:', 'AADSTS50126: Error validating credentials due to invalid username or password
0

There are 0 best solutions below