Learning and Sharing
  • Home
  • Blog
  • Linux
  • macOS
  • Virtualization
    • VMware
    • VirtualBox
  • Windows
    • Windows 11
    • Windows 10
    • Windows Server
  • Series
    • Symantec
    • Intune
    • Microsoft Azure
    • Powershell
    • VirtualBox
    • VMware
    • PowerShell Learning
    • Microsoft Graph
  • More
    • Auto Installation
    • AEC Installation
  • Contact
No Result
View All Result
  • Home
  • Blog
  • Linux
  • macOS
  • Virtualization
    • VMware
    • VirtualBox
  • Windows
    • Windows 11
    • Windows 10
    • Windows Server
  • Series
    • Symantec
    • Intune
    • Microsoft Azure
    • Powershell
    • VirtualBox
    • VMware
    • PowerShell Learning
    • Microsoft Graph
  • More
    • Auto Installation
    • AEC Installation
  • Contact
No Result
View All Result
No Result
View All Result

The Request did not Meet the Criteria to be Authenticated Successfully

September 18, 2023
in Blog, Powershell
0
ADVERTISEMENT

Table of Contents

SMTP Client not authenticated to send mail

In some cases, you are getting the below error while sending email from your apps, PowerShell or printers through Exchange Online Microsoft 365.

  • Error 5.7.57 Client not authenticated to send mail.
  • Error: 535 5.7.139 Authentication unsuccessful, the request did not meet the criteria to be authenticated successfully.

You should receive an email log like this:

Send-MailMessage : The SMTP server requires a secure connection or the client was not authenticated. The server response was: 5.7.57 Client not authenticated to send mail. Error: 535 5.7.139 Authentication unsuccessful, the request did not meet the criteria to be authenticated successfully. Contact your administrator.
[KU1PR03CA0044.apcprd03.prod.outlook.com]
At line:1 char:1
+ Send-MailMessage `
+ ~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (System.Net.Mail.SmtpClient:SmtpClient) [Send-MailMessage], SmtpExcept
ion
+ FullyQualifiedErrorId : SmtpException,Microsoft.PowerShell.Commands.SendMailMessage

The cause

  • The Security Defaults is enabled in your tenant.
  • The Security Defaults is disabled but the account using to sending email though SMTP submission was configured with MFA (Multi-Authen Factor).
  • The Security Defaults is disabled, and the user is not configured to use MFA, but the SMTP Authentication is disable at tenant level.

If your tenant was created on or after October 22, 2019, security defaults may be enabled in your tenant. To protect all of our users, Security Defaults are being rolled out to all new tenants at creation.

Note Note: You must disable Security Defaults in Azure Active Directory, when it enabled, it’ll disable basic authentication in whole tenant, and it overwrites all other settings. It means enable SMTP Authentication will not work.

The solution

Before you begin, we assume you have:

  • Disable the Security Defaults on your Microsoft 365 tenant.
  • Enable SMTP for specific email account in Microsoft 365.

If user has not configured with MFA, after you meet the two above prerequisites. The error should be gone automatically.

If the user that using to sending email has configured with MFA. You need to create an app password to authenticate using the SMTP client instead of using your account password.

Why we need to disable the Security Defaults? Because by default, the Security Defaults does not support app password.

To create an app password for a Microsoft 365 account, please follow this post.

Once the app password is created. Let’s using it on your apps, printers, scripts…to authenticate to sending email instead of using the normal password (the one you’re using to login into your account on the web).

The Request did not Meet the Criteria to be Authenticated Successfully

For example, we create a PowerShell script to sending an email through Microsoft 365 using the app password.

$password = ConvertTo-SecureString "dyzmpfnwxjhmhwyd" -AsPlainText -Force
$Cred = New-Object System.Management.Automation.PSCredential ("[email protected]", $password)

Send-MailMessage `
    -To "[email protected]" `
    -From "[email protected]" `
    -Subject "This is a test message from PowerShell" `
    -Body "Hello World!" `
    -Credential $Cred `
    -SmtpServer "smtp.office365.com" -Port 587 -UseSsl

As you can see on the below screenshot, when we use the app password to send the email. The email was sent, and the error was gone.

The Request did not Meet the Criteria to be Authenticated Successfully
The Request did not Meet the Criteria to be Authenticated Successfully

Not a reader? Watch this related video tutorial:

5/5 - (1 vote)
Previous Post

The SMTP Server Requires a Secure Connection, or the Client was not Authenticated

Next Post

Create an App Password Is Missing in Microsoft 365

Related Posts

Running Hyper-V and VMware Workstation on The Same Machine

August 15, 2024

How to Uninstall All Autodesk Products At Once Silently

July 29, 2024
Ftr5

How to Uninstall the Autodesk Genuine Service on Windows

July 29, 2024
Ftr19

How to Fix Windows Cannot Read the ProductKey From the Unattend Answer File in VirtualBox

July 26, 2024
Ftr25

How to Update Windows Terminal in Windows 10/11

July 26, 2024

How to Disable The Beep Sound in WSL Terminal on Windows

July 26, 2024

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Recent Posts

  • How To Turn On uBlock Origin Extension in Chrome (2025)
  • Images Hidden Due To Mature Content Settings In CivitAI
  • Azure OpenAI vs Azure AI Hub, How to Choose the Right One for Your Needs

Categories

Stay in Touch

Discord Server

Join the Discord server with the site members for all questions and discussions.

Telegram Community

Jump in Telegram server. Ask questions and discuss everything with the site members.

Youtube Channel

Watch more videos, learning and sharing with Leo ❤❤❤. Sharing to be better.

Newsletter

Join the movement and receive our weekly Tech related newsletter. It’s Free.

General

Microsoft Windows

Microsoft Office

VMware

VirtualBox

Technology

PowerShell

Microsoft 365

Microsoft Teams

Email Servers

Copyright 2025 © All rights Reserved. Design by Leo with ❤

No Result
View All Result
  • Home
  • Linux
  • Intune
  • macOS
  • VMware
  • VirtualBox
  • Powershell
  • Windows 10
  • Windows 11
  • Microsoft 365
  • Microsoft Azure
  • Microsoft Office
  • Active Directory

No Result
View All Result
  • Home
  • Linux
  • Intune
  • macOS
  • VMware
  • VirtualBox
  • Powershell
  • Windows 10
  • Windows 11
  • Microsoft 365
  • Microsoft Azure
  • Microsoft Office
  • Active Directory