< Back

New-PAOrder

Sat Jan 18, 2020 7:32 pm

NAME New-PAOrder



SYNOPSIS

Create a new order on the current ACME account.





SYNTAX

New-PAOrder [-Domain] <String[]> [[-KeyLength] <String>] [-OCSPMustStaple] [-NewKey] [-FriendlyName <String>]

[-PfxPass <String>] [-Install] [-Force] [-WhatIf] [-Confirm] [<CommonParameters>]



New-PAOrder [-CSRPath] <String> [-Force] [-WhatIf] [-Confirm] [<CommonParameters>]





DESCRIPTION

Creating an ACME order is the first step of the certificate request process. To create a SAN certificate with

multiple names, include them all in an array for the -Domain parameter. The first name in the list will be

considered the "MainDomain" and will also be in the certificate subject field. LetsEncrypt currently limits SAN

certificates to 100 names.



Be aware that only one order per MainDomain can exist with this module. Subsequent orders that have the same

MainDomain will overwrite previous orders and certificates under the assumption that you are trying to renew or

update the certificate with additional names.





PARAMETERS

-Domain <String[]>

One or more domain names to include in this order/certificate. The first one in the list will be considered

the "MainDomain" and be set as the subject of the finalized certificate.



Required? true

Position? 1

Default value

Accept pipeline input? false

Accept wildcard characters? false



-CSRPath <String>

The path to a pre-made certificate request file in PEM (Base64) format. This is useful for appliances that

need to generate their own keys and cert requests.



Required? true

Position? 1

Default value

Accept pipeline input? false

Accept wildcard characters? false



-KeyLength <String>

The type and size of private key to use. For RSA keys, specify a number between 2048-4096 (divisible by 128).

For ECC keys, specify either 'ec-256' or 'ec-384'. Defaults to '2048'.



Required? false

Position? 2

Default value 2048

Accept pipeline input? false

Accept wildcard characters? false



-OCSPMustStaple [<SwitchParameter>]

If specified, the certificate generated for this order will have the OCSP Must-Staple flag set.



Required? false

Position? named

Default value False

Accept pipeline input? false

Accept wildcard characters? false



-NewKey [<SwitchParameter>]

If specified, a new private key will be generated for the certificate order. Otherwise, the old key is re-used

if it exists. This is useful if you believe the current key has been compromised.



Required? false

Position? named

Default value False

Accept pipeline input? false

Accept wildcard characters? false



-FriendlyName <String>

Set a friendly name for the certificate. This will populate the "Friendly Name" field in the Windows

certificate store when the PFX is imported. Defaults to the first item in the Domain parameter.



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-PfxPass <String>

Set the export password for generated PFX files. Defaults to 'poshacme'.



Required? false

Position? named

Default value poshacme

Accept pipeline input? false

Accept wildcard characters? false



-Install [<SwitchParameter>]

If specified, the certificate generated for this order will be imported to the local computer's Personal

certificate store.



Required? false

Position? named

Default value False

Accept pipeline input? false

Accept wildcard characters? false



-Force [<SwitchParameter>]

If specified, confirmation prompts that may have been generated will be skipped.



Required? false

Position? named

Default value False

Accept pipeline input? false

Accept wildcard characters? false



-WhatIf [<SwitchParameter>]



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Confirm [<SwitchParameter>]



Required? false

Position? named

Default value

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

PoshACME.PAOrder





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



PS C:\\>New-PAOrder site1.example.com



Create a new order for the specified domain using the default key length.









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



PS C:\\>New-PAOrder -Domain 'site1.example.com','site2.example.com','site3.example.com'



Create a new SAN order for the specified domains using the default key length.









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



PS C:\\>New-PAOrder site1.example.com 4096



Create a new order for the specified domain using an RSA 4096 bit key.









-------------------------- EXAMPLE 4 --------------------------



PS C:\\>New-PAOrder 'site1.example.com','site2.example.com' ec-384 -Force



Create a new SAN order for the specified domains using an ECC key using P-384 curve that ignores any confirmations.











RELATED LINKS

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

Get-PAOrder

Set-PAOrder