< Back

Install-PACertificate

Sat Jan 18, 2020 7:31 pm

NAME Install-PACertificate



SYNOPSIS

Install a Posh-ACME certificate into a Windows certificate store.





SYNTAX

Install-PACertificate [[-PACertificate] <Object>] [[-StoreLocation] <String>] [[-StoreName] <String>]

[-NotExportable] [<CommonParameters>]





DESCRIPTION

This can be used instead of the -Install parameter on New-PACertificate to import a certificate with more

configurable options.





PARAMETERS

-PACertificate <Object>

The PACertificate object you want to import. This can be retrieved using Get-PACertificate and is also

returned from things like New-PACertificate and Submit-Renewal.



Required? false

Position? 1

Default value

Accept pipeline input? true (ByValue)

Accept wildcard characters? false



-StoreLocation <String>

Either 'LocalMachine' or 'CurrentUser'. Defaults to 'LocalMachine'.



Required? false

Position? 2

Default value LocalMachine

Accept pipeline input? false

Accept wildcard characters? false



-StoreName <String>

The name of the certificate store to import to. Defaults to 'My'. The store must already exist and will not be

created automatically.



Required? false

Position? 3

Default value My

Accept pipeline input? false

Accept wildcard characters? false



-NotExportable [<SwitchParameter>]

If specified, the private key will not be marked as Exportable.



Required? false

Position? named

Default value False

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS



OUTPUTS



-------------------------- EXAMPLE 1 --------------------------



PS C:\\>Install-PACertificate



Install the certificate for the currently selected order to the default LocalMachine\\My store.









-------------------------- EXAMPLE 2 --------------------------



PS C:\\>Get-PACertificate example.com | Install-PACertificate



Install the specified certificate to the default LocalMachine\\My store.









-------------------------- EXAMPLE 3 --------------------------



PS C:\\>Install-PACertificate -StoreLocation 'CurrentUser' -NotExportable



Install the certificate for the currently selected order to the CurrentUser\\My store and mark the private key as

not exportable.











RELATED LINKS

Project: https://github.com/rmbolger/Posh-ACME

Get-PACertificate