Enable WS-Man in HTTPS mode for discovering Windows or Hyper-V servers
By default, the WS-Man service is not enabled on the Windows servers. You must enable the WS-Man service on target servers in HTTPS mode.
Pre-requisites:
IIS with HTTPS enabled
WS-Man service with HTTPS enabled
PowerShell 4.0 to configure the WS-Man service with certificate
Creating a Self-Sign Certificate
NOTE: If you have a publicly-signed certificate, things are easier and you can use Set-WSManQuickConfig -UseSSL. Run the following command on PowerShell by logging in as an administrator:
It is important to enter the name of the server that you want to manage remotely to the ‑DnsName parameter. If the server has a DNS name, you must use the fully qualified domain name (FQDN).
NOTE: The $Cert variable is important because it stores thumbprint for future command use.
Creating PowerShell Remoting on the host system
The Enable-PSRemoting command also starts a WS-Man listener, but only for HTTP.
Enable-PSRemoting -SkipNetworkProfileCheck -Force
If you do not want anyone to use HTTP to connect to the server, you can remove the HTTP listener by running the command:
NOTE: Use the $Cert variable that you defined earlier to read the Thumbprint. This variable allows the New-Item cmdlet to locate the certificate in your certificates store.