Hi guys, this is a weird one, can someone please help?
I am trying to create Exchange 2016 PowerShell session, it works outside of PSUD, but when I run it within UD page, I get below error:
New-PSSession : Cannot process argument transformation on parameter 'Credential'. The method or operation is not implemented.
At line:8 char:161
+ ... .local/PowerShell/" -Authentication Kerberos -Credential $psexchROsvc
+ ~~~~~~~~~~~~
+ CategoryInfo : InvalidData: (:) [New-PSSession], ParameterBindingArgumentTransformationException
+ FullyQualifiedErrorId : ParameterArgumentTransformationError,Microsoft.PowerShell.Commands.NewPSSessionCommand
The command I am running is straight forward and should work to be fair, but it craps out and I am out of ideas: New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri "http://exchange.domain.local/PowerShell/" -Authentication Kerberos -Credential $psexchROsvc
I wonder if this has to do with the PSUD PowerShell host. I’ll add it to my todo list to check this out. I take it $psexchROsvc is an PSCredential object?
Thanks, @adam
Not sure if helps, but I have commented out below part and getting different error. Ofc, I’m just messing around here as I need those params
Error: Self referencing loop detected for property 'module' with type 'System.Management.Automation.PSModuleInfo'. Path '[1].exportedFunctions.add-DistributionGroupMember'.
Just want to throw in that I get same exact error with other cmdlets that use -Credential params, too:
Get-ADUser "RAYMIX" -Credential $psadROsvc
Hopefully that helps you with the pattern of the issue
Offtopic: I’m gonna have to postpone my UD project until these gets resolved because every page will fundamentally depend on it, lol (least-privilege models, JEA and all that fun stuff).
I also noticed the new features in 1.4, damn dudes, well done! I was shaking in excitement reading patch notes Can’t wait!
Is it possible that that credential variable is null? The reason it’s throwing the not implemented exception is because the UDHost is attempting to prompt for a credential but that isn’t implemented in UD.
I ask because when I try this, this is the result.
[09-25-20 10:55:17 AM] PS: [localhost] Connecting to remote server localhost failed with the following error message : Access is denied. For more information, see the about_Remote_Troubleshooting Help topic.
@adam well that’s super embarrassing, lol. You’re absolutely right the credentials were null within UD.
I completely forgot that Cache is a custom made scope and won’t work like below