< Back

Remove-AzureKeyVaultCertificate

Tue Jan 29, 2019 9:50 pm

NAME Remove-AzureKeyVaultCertificate



SYNOPSIS

Removes a certificate from a key vault.





SYNTAX

Remove-AzureKeyVaultCertificate [-InputObject] <PSKeyVaultCertificateIdentityItem> [-DefaultProfile <IAzureContextContainer>] [-Force]

[-InRemovedState] [-PassThru] [-Confirm] [-WhatIf] [<CommonParameters>]



Remove-AzureKeyVaultCertificate [-VaultName] <String> [-Name] <String> [-DefaultProfile <IAzureContextContainer>] [-Force] [-InRemovedState]

[-PassThru] [-Confirm] [-WhatIf] [<CommonParameters>]





DESCRIPTION

The Remove-AzureKeyVaultCertificate cmdlet removes a certificate from a key vault.





PARAMETERS

-DefaultProfile <IAzureContextContainer>

The credentials, account, tenant, and subscription used for communication with azure



Required? false

Position? named

Default value None

Accept pipeline input? False

Accept wildcard characters? false



-Force [<SwitchParameter>]

Forces the command to run without asking for user confirmation.



Required? false

Position? named

Default value False

Accept pipeline input? False

Accept wildcard characters? false



-InputObject <PSKeyVaultCertificateIdentityItem>

Certificate Object.



Required? true

Position? 0

Default value None

Accept pipeline input? True (ByValue)

Accept wildcard characters? false



-InRemovedState [<SwitchParameter>]

If present, removes the previously deleted certificate permanently



Required? false

Position? named

Default value False

Accept pipeline input? False

Accept wildcard characters? false



-Name <String>

Specifies the name of the certificate that this cmdlet removes from a key vault. This cmdlet constructs the fully qualified domain name (FQDN)

of a certificate based on the name that this parameter specifies, the name of the key vault, and your current environment.



Required? true

Position? 1

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-PassThru [<SwitchParameter>]

Returns an object representing the item with which you are working. By default, this cmdlet does not generate any output.



Required? false

Position? named

Default value False

Accept pipeline input? False

Accept wildcard characters? false



-VaultName <String>

Specifies the name of the key vault from which this cmdlet removes a certificate. This cmdlet constructs the FQDN of a key vault based on the

name that this parameter specifies and your current environment.



Required? true

Position? 0

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-Confirm [<SwitchParameter>]

Prompts you for confirmation before running the cmdlet.



Required? false

Position? named

Default value False

Accept pipeline input? False

Accept wildcard characters? false



-WhatIf [<SwitchParameter>]

Shows what would happen if the cmdlet runs. The cmdlet is not run.Shows what would happen if the cmdlet runs. The cmdlet is not run.



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 (http://go.microsoft.com/fwlink/?LinkID=113216).



INPUTS

None

This cmdlet does not accept any input.





OUTPUTS

Microsoft.Azure.Commands.KeyVault.Models.PSDeletedKeyVaultCertificate







NOTES









Example 1: Remove a certificate



PS C:\\>Remove-AzureKeyVaultCertificate -VaultName "ContosoKV01" -Name "SelfSigned01" -PassThru -Force

Name : selfSigned01

Certificate :

Thumbprint :

Tags :

Enabled : True

Created : 2/8/2016 11:29:33 PM

Updated : 2/8/2016 11:29:33 PM



This command removes the certificate named SelfSigned01 from the key vault named ContosoKV01. This command specifies the Force parameter.

Therefore, the cmdlet does not prompt you for confirmation.





Example 3: Purge the deleted certificate from the key vault permanently



PS C:\\>Remove-AzureKeyVaultCertificate -VaultName 'Contoso' -Name 'MyCert' -InRemovedState



This command permanently removes the certificate named 'MyCert' from the key vault named 'Contoso'. Executing this cmdlet requires the 'purge'

permission, which must have been previously and explicitly granted to the user on this key vault.







RELATED LINKS

Online Version: https://docs.microsoft.com/en-us/powers ... ertificate

Add-AzureKeyVaultCertificateContact

Get-AzureKeyVaultCertificate

Import-AzureKeyVaultCertificate

Undo-AzureKeyVaultCertificateRemoval