01 02 03 04 05 06 07 08 09 10 | # Part 1: enable client mode on the local jump box $remoteComputer = 'SHERVER009' Enable-WSManCredSSP Client -DelegateComputer $remoteComputer -Force # Part 2: enable server mode at the destination machine Enable-WSManCredSSP Server # Part 3: execute WinRM command with CredSSP $credentials = Get-Credential Invoke-Command -ComputerName $remoteComputer -ScriptBlock {ping localhost} -Authentication CredSSP |
Categories: