Powershell remote access denied on workgroup

I've configured a domenstic network with PCs running windows 10 and I'm trying to set up remote access via powershell between these hosts. I've enabled remote access on all the hosts, authorizing all the hosts to control AND be controlled by all the hosts in the network, I've tested the connection between two PCs and it seems to be working cause the following returns no error:

 PS C:\WINDOWS\system32> test-WSman 192.168.1.132 wsmid : ProtocolVersion : ProductVendor : Microsoft Corporation ProductVersion : OS: 0.0.0 SP: 0.0 Stack: 3.0

but, when I try to establish a full session between the two hosts with the following command, I get error:

 PS C:\WINDOWS\system32>Enter-PSSession -ComputerName 192.168.1.132 -Credential User1 Enter-PSSession : Connecting to remote server 192.168.1.132 failed with the following error message : Access is denied. For more information, see the about_Remote_Troubleshooting Help topic. At line:1 char:1 + Enter-PSSession -ComputerName 192.168.1.132 -Credential User1 + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : InvalidArgument:(192.168.1.132:String) [Enter-PSSession], PSRemotingTransportException + FullyQualifiedErrorId : CreateRemoteRunspaceFailed 

After issuing this command, of course, pops-up the dialog box, asking for password. Maybe, the error could be in the credential I'm issuing...where do I get valid and acceptable credentials(user & password) in Windows, for connecting to a remote machine in my home network?

Do I need to create new ones, with get-credential cmdlet, or maybe credentials are tied to the local account on the machine I'm connecting from, or perhaps on the machine I'm connecting to? I'm totally inexpert in this field so I don't know how to solve it

P.S. I'm in a simply windows workgroup(with no home-group setted), not in a domain so the machines are in peer-to-peer configuration

2 Answers

There are a few PoSH remoting cmdlets that can be used without being administrator or even needing WinRM on the remote host:

Tip: Work Remotely with Windows PowerShell without using Remoting or

WinRM

But for much of PoSH remoting, you must be in the local administrators group on the remote host.

See also:

PowerShell Remoting without administrator rights

PowerShell Remoting via WinRM for Non-Admin Users

Configuring WinRM over HTTPS to enable PowerShell remoting

on the computer you are connecting from you will to run need this in admin powershell

Set-Item WSMan:\localhost\Client\TrustedHosts -Value "*" –Force

this makes your computer trust the one you are connecting to (* is all computers) then do

New-PSSession –computername 192.168.1.7 –credential nameofcomputer\administrator

you need the computername and the useraccount on that computer then put in password and it will work then

Enter-PSSession
1

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like