79178669

Date: 2024-11-11 17:57:16
Score: 1.5
Natty:
Report link

https://learn.microsoft.com/en-us/powershell/module/pki/new-selfsignedcertificate?view=windowsserver2022-ps

$params = @{DnsName = 'www.fabrikam.com', 'www.contoso.com' 
CertStoreLocation = 'Cert:\LocalMachine\My' } 

New-SelfSignedCertificate @params 

OR

New-SelfSignedCertificate -DnsName 'www.fabrikam.com','www.contoso.com' -CertStoreLocation Cert:\LocalMachine\My

These two examples create a self-signed SSL server certificate in the computer MY store with the subject alternative names www.fabrikam.com and www.contoso.com and the Subject and Issuer name set to www.fabrikam.com. (First one will be set to subject/Issuer unless otherwise indicated.

Reasons:
  • Probably link only (1):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Jlicari