When executing a powershell script / commands on a remote computer, does it pass the credentials in clear text? I currently use PSExec to remotely install / remove third party software and need to get away from this since it sends credentials in clear text.
I have some powershell scripts that allow me to install software on remote computers as well. Some of the commands include:
Invoke-Command -ComputerName $computer -ScriptBlock {Start-Process 'C:\$process' -ArgumentList '/s' -verb runas}
and:
Invoke-WmiMethod -ComputerName $computer -Class Win32_Process -Name Create -ArgumentList "c:\$process"
Also I use New-Item, Copy-Item, and Remove-Item in the scripts. When I run the scripts, I run powershell as administrator, entering my domain admin credentials upon opening powershell. That is the only time I enter credentials. I do not have the -Credential parameter anywhere in the script.
So, my question is - since my script does not ever ask me for credentials, how are these credentials being passed to the remote computers, and is it encrypted / more secure than PSExec? Thank you.