WinRM SSL certificate expired, How to fix it?

I understand that an expired WinRM SSL certificate error is coming up when executing the Powershell script.

Try running through the following to see if it resolves the issue:

  1. Navigate to Lifecycle Services.
  2. In the Shared Asset library, click the Model
  3. Download the Renew WinRM certificate folder
  4. RDP to the environment
  5. Extract the zip file to a local folder
  6. Open mmc.exe and add Certificate snap-in (Computer)
  7. Open Personal\Certificates and locate the certificate with your VMs name which should have the expiration date passed
  8. Browse to the RenewWinRMCertificate folder that was previously created from extracting the zip file
  9. Right-click the file, select properties, and unblock it (if you see this option).
  10. Select File > Open Windows PowerShell with elevated privileges (Run as Administrator)
  11. Run .\VirtualMachine-RegenerateWinRMCertificate.ps1 from the folder.

The result should be something like this:

  1. Refresh the Certificates console and confirm the Certificate has been created and the expiration date is now valid. (Optional: Delete expired certificate to avoid confusion)
  2. Restart the Environment from LCS (Stop \ Start)
  3. In LCS select Maintain > Rotate secrets

Select ‘Rotate the SSL certificates‘.

Leave a comment