Forum Discussion
Chris Johnston
May 08, 2019Brass Contributor
Azure Automation connecting to Exchange with MFA enforced
I have a tenant with MFA a requirement for any account with elevated privileges. I can use Azure Automation PowerShell runbook for Azure AD using the service principal and certificate e.g. # Get ...
- Oct 08, 2019
Chris Johnston The answer is deceptively simple....
I published a Runbook script to get you started with the initial connection, then you can add your own script form there on.
Chris Johnston
May 09, 2019Brass Contributor
Richard_Hooper I have used the equivalent for automation, i.e. app secret for services that can accept these connection parameters e.g. PnP
$servicePrincipalConnection=Get-AutomationConnection -Name "AzureRunAsConnection"
$appsecret = Get-AutomationVariable -Name "SPAppSecret"
Connect-PnPOnline -AppId $servicePrincipalConnection.ApplicationId -AppSecret $appsecret -Url ""
I don't see where Exchange connection supports app secrets.
Would you be able to provide a working or theoretical example of how the connection to Exchange online would use an application password as you suggest please as I'm not sure how I'd do this.
RobOnyxPublishing
Feb 17, 2021Copper Contributor
Hi Richard
could you explain how you use create and use App Secret for connecting to PnP Connect-PnPOnline
could you explain how you use create and use App Secret for connecting to PnP Connect-PnPOnline