Forum Discussion

Michael Sodolak's avatar
Michael Sodolak
Copper Contributor
Apr 11, 2018

Unable to connect to PowerShell for Security and Compliance

I was able to previously connect to Powershell with my credentials.  I am able to connect to the Web Portal with the same credentials and I am a Global Admin of my domain. 

 

$msolcred = get-credential

$SCCSession = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.compliance.protection.outlook.com/powershell-liveid -Credential $msolcred -Authentication Basic -AllowRedirection

 

I receive the following error:

[ps.compliance.protection.outlook.com] Connecting to remote server failed with the following error message : Access is
denied. For more information, see the about_Remote_Troubleshooting Help topic.
    + CategoryInfo          : OpenError: (System.Manageme....RemoteRunspace:RemoteRunspace) [], PSRemotingTransportExc
   eption
    + FullyQualifiedErrorId : PSSessionOpenFailed

 

I am able to connect to the other O365 Powershell (i.e. $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.outlook.com/powershell-liveid?DelegatedOrg=<domain.name> -Credential $msolcred -Authentication Basic -AllowRedirection) and can perform whatever tasks I need.   

 

I have confirmed access to eDiscovery Manager in Security and Compliance and all other rights flow down from my being a Global Admin. 

 

This is not a credentials issue as the error alludes since my credentials work everywhere else, just not in the Security and Complaince for powershell.  They do work for https://protection.office.com/#/contentsearch

 

Anyone have any ideas on how to fix this issue and grant permission?  

Resources