Get-Certificate -Template 'Templatename' -CertStoreLocation 'cert:\LocalMachine\My' -Credential (get-credential)
And check you rights for this cert template.
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
I need to issue a certificate for a server. I run these commands:
$cred = Get-Credential Get-Certificate -Template Templatename -CertStoreLocation Cert:\LocalMachine\My -Credential $cred
But after the second command I get this error:
Get-Certificate :
At line:1 char:1
+ Get-Certificate -Template Templatename -CertStoreLocation Cert:\LocalMachine\ ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Get-Certificate], ParameterBindingException
+ FullyQualifiedErrorId : RuntimeException,Microsoft.CertificateServices.Commands.GetCertificateCommand
What's this? I mean, there's no description of the error. What's wrong? Is that something in the command syntax, is something wrong with the server, with the network... How do I solve this?
Get-Certificate -Template 'Templatename' -CertStoreLocation 'cert:\LocalMachine\My' -Credential (get-credential)
And check you rights for this cert template.
Sorry for the confusion, I meant to say upgrade Powershell not the OS.
What OS is the server running? If possible see if you can upgrade Powershell to 5.1.
If you look at the properties of the template "Templatename", do you have permission to "Read" and "Enroll" using the template (either explicitly or through security group membership)?
Are you getting any error codes like 0x<RandomNumbersandLetters>?