Non-Active Directory Remote Powershell
SETUP Powershell Remote
Enable Powershell to allow remote sessions on the computer you want to remotely
access.
cmdlet: Enable-PSRemoting -Force
Allow unencrypted traffic since the computers are not in trusted domain.
cmdlet: Set-Item WSMan:\localhost\Client\AllowUnencrypted $true
Allow basic authentication (input username and password)
cmdlet: Set-Item WSMan:\localhost\Service\Auth\Basic $true
Configure the WinRM service (Windows Remote Management)
cmdlet: winrm quickconfig
Disable the firewall or add a firewall rule to allow WinRM traffic
Search > Windows Security > Firewall & Network protection (disable public,
private, and domain)
Search > Windows Defender Firewall with Advanced Security (allow WinRM
traffic)
If your Password is not Password01 set your credentials using:
cmdlet: $cred = Get-Credential -UserName “WORKGROUP-PC\LocalUser”
This will prompt you to supply the credentials for the remote computer you are
trying to access.
ENTER Remote Powershell Session
Connect to the Remote machine from your local computer
cmdlet: Enter-PSSession -ComputerName REMOTE-MACHINE
Run neccessary commands (these will be executed on the remote computer)
Example: Get-Process
List all running processes on the target computer
EXIT Remote Powershell Session
cmdlet: Exit-PSSession