I have an old Python application that suing Imaplib to read email, download attachments from email in inbox folder, But using basic authentication like:
mail = imaplib.IMAP4_SSL(SERVER)
mail.login(EMAIL, PASSWORD)
mail.select('inbox')
But, Microsoft is about to turn off Basic Authentication for IMAP that mean I must update to OAuth 2.0 for my application to continue working. But I've searched on internet and only find example of imaplib + OAuth2 for gmail or using win32com.client which only work on Windows (my application is running on Ubuntu).
I hope that I don't have to use other library because I have to change a lot in my code.So anyone know where to find an example about using imaplib + OAuth2.0 to access outlook mail box?