Hi,
I am attempting to connect to the Security & Compliance centre remotely. Last week this was working a lot of the time (optimistically >50% of the time), however, as of Monday (24th September) I am only getting errors - see below.
I have checked and eliminated the following as reason this isn't working:
- The username and password are 100% correct
- The account does not have MFA
- The account has the correct authorisation roles
I cannot use the Exchange Online PowerShell Module provided by Microsoft as this has to be done remotely.
A potential I may have identified is that the redirect isn't working or is being blocked, whether this is a Microsoft thing or an internal network thing I cannot be sure as I do not know what the ps.compliance.protection.outlook <g class="gr_ gr_46 gr-alert gr_spell gr_inline_cards gr_run_anim ContextualSpelling ins-del multiReplace" data-gr-id="46" id="46">url</g> redirects to or how to connects to my domains centre.
So my Two Questions are:
- Has anyone ever come across this issue before and has a potential solution?
- What are the next steps in the connection process that occur in order to connect directly to my domain? i.e. URLs (generic) and/or ports?
Code used to connect
$session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.compliance.protection.outlook.com/powershell-liveid/ -Credential $cred -Authentication Basic -AllowRedirection
Error messge received:
New-PSSession : [ps.compliance.protection.outlook.com] Connecting to remote server ps.compliance.protection.outlook.com failed with the following error message : Access is denied. For more information, see the about_Remote_Troubleshooting Help topic. At line:31 char:16+ ... $session = New-PSSession -ConfigurationName Microsoft.Exchange -Conn ...+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~+ CategoryInfo : OpenError: (System.Manageme....RemoteRunspace:RemoteRunspace) [New-PSSession], PSRemotingTransportException+ FullyQualifiedErrorId : AccessDenied,PSSessionOpenFailed