Barry.Collins 0 Posted September 25, 2015 (edited) After many hours of frustration I've finally got this to work. This will give you the full Powershell experience as if you'd used Enter-PSSession to access a server in your own LAN. (Requires Tunnels!) Name: Powershell Program: %windir%\system32\WindowsPowershell\v1.0\powershell.exe Arguments: -noexit -command "$cred = get-credential; enter-pssession localhost -port %LocalPort1% -credential $cred" LocalPort: 0 LocalIP: 127.0.0.1 RemotePort: 5985 RemoteIP: %RemoteIP% Socket Function: TCPLocalListen If you have the correct credentials set against the location you can use the following arguments to connect without having to manually enter them each time: -noexit -command "$secpasswd = ConvertTo-SecureString '%computerpassword%' -AsPlainText -Force; $cred = New-Object System.Management.Automation.PSCredential ('%computerdomain%\%computerusername%', $secpasswd); enter-pssession localhost -port %LocalPort1% -credential $cred" Edited September 26, 2015 by Guest Quote Share this post Link to post Share on other sites
0 mcmcghee 1 Posted September 25, 2015 This is awesome! I've been trying to get this working for a while. Unfortunately its not working for me. Does remoteport need to be %remoteip% or is that a typo? Quote Share this post Link to post Share on other sites
0 Barry.Collins 0 Posted September 26, 2015 That would be a typo. Sorry! It's now fixed. Quote Share this post Link to post Share on other sites
0 Alex.Graf 2 Posted September 28, 2015 Works great. Thanks for posting the setup you used! Quote Share this post Link to post Share on other sites
0 kurtwoods 0 Posted December 8, 2015 I was glad to find this and it works wonderfully. However, I was wondering if there is a way to connect to a session (or add the pssnapin) for Exchange management. That would be super awesome! Thanks, kurt Quote Share this post Link to post Share on other sites
0 rgreen83 3 Posted February 3, 2016 This is great, thank you for sharing! Quote Share this post Link to post Share on other sites
0 timwiser 11 Posted May 6, 2016 Hi, This sounds really handy but I'm struggling to get it working. I'm wondering whether I need to specify any additional items on the config? I've gone to the dashboard -> Config -> Redirected Apps, and added a new redirector and then added the Redirected Ports line. I also checked the Basic, Device and Computer boxes as that needed doing before the Powershell item would appear on the network redirectors menu. My issue is that, if I initiate a Powershell session against a remote device, a Powershell window does indeed appear but it's against my local device rather than the remote one. Quote Share this post Link to post Share on other sites
0 tlphipps 20 Posted May 6, 2016 Tim, search here for the powershell plugin. MUCH more integrated, newer solution. Sent from my SAMSUNG-SM-G930A using Tapatalk Quote Share this post Link to post Share on other sites
0 christiannancy 0 Posted October 19, 2016 The PowerShell plugin from Squidworks doesn't seem to work for me so I have been playing with this solution for a couple days now, with mixed results. For servers, it appear to run just fine, Windows 8 and Windows 10 appear to be working as well. However I have tried it to remote into Windows 7 Pro machines and I have "Access denied" failures right and left for no rhyme or reason. I run "winrm quickconfig -quiet" in elevated command prompt with no errors, yet some machines just won't let me in. All those are domain joined (different domains at different clients) and each time I use a domain admin account yet no dice. Not sure where I could find/enable logs that would give me more details than "Access denied". There are tons of results on Google but they all have to do with not being able to run winrm properly in the first place. Anybody has any clue on getting a handle on this? Thanks, Christian Quote Share this post Link to post Share on other sites
After many hours of frustration I've finally got this to work.
This will give you the full Powershell experience as if you'd used Enter-PSSession to access a server in your own LAN.
(Requires Tunnels!)
Name: Powershell
Program: %windir%\system32\WindowsPowershell\v1.0\powershell.exe
Arguments: -noexit -command "$cred = get-credential; enter-pssession localhost -port %LocalPort1% -credential $cred"
LocalPort: 0
LocalIP: 127.0.0.1
RemotePort: 5985
RemoteIP: %RemoteIP%
Socket Function: TCPLocalListen
If you have the correct credentials set against the location you can use the following arguments to connect without having to manually enter them each time:
-noexit -command "$secpasswd = ConvertTo-SecureString '%computerpassword%' -AsPlainText -Force; $cred = New-Object System.Management.Automation.PSCredential ('%computerdomain%\%computerusername%', $secpasswd); enter-pssession localhost -port %LocalPort1% -credential $cred"
Edited by GuestShare this post
Link to post
Share on other sites