Using just a password-based authentication, it's easy to authenticate in CSOM from my C# application:
context.Credentials = new SharePointOnlineCredentials(username, password);
But how to authenticate when Multi-factor authentication (MFA) is activated?
Since the MFA was activated in the tenant, i get the error:
The sign-in name or password does not match one in the Microsoft account system
Microsoft.SharePoint.Client.Idcrl.IdcrlAuth.GetServiceToken
Is there any way?
I´ve read about using APP PAssword, but the new password created doesn´t work from C# code
Thanks.