Create Office 365 Safe Attachments Policy and Safe attachment Rule using PowerShell To get started with creating the Safe attachment policy and safe attachment rule a connection to Exchange Online Protection needs to be established. To establish a connection to Exchange Online Protection (EOP), follow the below.
1 |
$UserCredential = Get-Credential |
1 |
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.protection.outlook.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection |
Then import the new session
1 |
Import-PSSession $Session -DisableNameChecking |
…
Leave a Comment