< Back

New-CSCertificate

Sun Jan 19, 2020 6:36 pm

NAME New-CSCertificate



SYNOPSIS

Creates a new PFX certificate for the CredentialStore encryption.





SYNTAX

New-CSCertificate [-CRTAttribute] <Object> [[-KeyName] <String>] [[-CertName] <String>] [-WhatIf] [-Confirm]

[<CommonParameters>]





DESCRIPTION

Use this function to create a custom self signed certificate used by the PSCredentialStore module.





PARAMETERS

-CRTAttribute <Object>

Provide certificate related attributes provided by function New-CRTAttribute.



Required? true

Position? 1

Default value

Accept pipeline input? true (ByValue)

Accept wildcard characters? false



-KeyName <String>

Provide a custom full path and name for the private key. The file extension has to be `*.key`.



Required? false

Position? 2

Default value ./private.key

Accept pipeline input? false

Accept wildcard characters? false



-CertName <String>

Provide a custom full path and name for the PFX certificate file. The file extension has to be `*.pfx`



Required? false

Position? 3

Default value ./certificate.pfx

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

[PSCredentialStore.Certificate.Attribute]





OUTPUTS

[None]





NOTES





- File Name : New-CSCertificate.ps1

- Author : Marco Blessing - marco.blessing@googlemail.com

- Requires :



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



PS C:\\>New-CSCertificate -CRTAttribute $CRTAttribute -KeyName './myprivate.key' -CertName './mycert.pfx'















RELATED LINKS

https://github.com/OCram85/PSCredentialStore