0

I am able to connect to a remote windows machine from my windows local machine using Powershell session created by New-PSSession command.

New-PSSession -ComputerName $computerName -Credential $cred

Now, I need to create similar remote session to a remote windows machine from my local LINUX machine. So, I installed powershell 6.0.2 on my red hat 7 linux box. When trying to create a remote session using New-PSSession command, I am getting following error:

New-PSSession : MI_Result_Access_Denied

I need to use only WinRM based approach and not SSH based as I cannot install any extra utility on remote windows machines.

Vishwanath
  • 149
  • 2
  • 14
  • You could find an answer [here](https://stackoverflow.com/questions/43743601/powershell-connecting-from-a-linux-client-to-a-windows-remote). Probably [this answer](https://stackoverflow.com/a/51722419/3641635). – Zilog80 May 03 '21 at 11:18
  • Does this answer your question? [Powershell connecting from a linux client to a windows remote](https://stackoverflow.com/questions/43743601/powershell-connecting-from-a-linux-client-to-a-windows-remote) – Zilog80 May 03 '21 at 11:19
  • No. I need to create remote sessions using WinRM and not SSH based. – Vishwanath May 03 '21 at 13:02
  • I have re read the question [Powershell connecting from a linux client to a windows remote](https://stackoverflow.com/questions/43743601/powershell-connecting-from-a-linux-client-to-a-windows-remote) and it seems exactly applying to your case. The question title may not be well phrased, but if you read the question you'll see that it describes exactly your case, connecting with WinRM and getting `MI_RESULT_ACCESS_DENIED`. It's from ArchLinux instead of RE7, but i don't think that these may be of any concern here. – Zilog80 May 03 '21 at 13:07
  • I get it, you mean that the [SSH answer](https://stackoverflow.com/a/51722419/3641635) doesn't fit your goal ? Then you should edit your question to precise this. – Zilog80 May 03 '21 at 13:16
  • It seems the support for WinRM through OPI is now functional. Anyway it requires Microsoft OMI on the server, and NTLM on OMI setup on the client. Maybe you've already have OMI on the remote Windows server ? – Zilog80 May 04 '21 at 18:41

1 Answers1

0

kerberos auth is not supported in cross domain in its vanilla flavour. and Basic auth over HTTP is not supported from Linux. Installing OpenSSH on windows looks to be only way.

Vishwanath
  • 149
  • 2
  • 14