Remove-​Azure​Rm​AD​App​Credential

Removes a credential from an application.

Syntax

Remove-AzureRmADAppCredential
      [-All]
      [-Force]
      -ObjectId <String>
      [-Confirm]
      [-WhatIf]
      [<CommonParameters>]
Remove-AzureRmADAppCredential
      [-All]
      -ApplicationId <String>
      [-Force]
      [-Confirm]
      [-WhatIf]
      [<CommonParameters>]
Remove-AzureRmADAppCredential
      -ApplicationId <String>
      [-Force]
      -KeyId <Guid>
      [-Confirm]
      [-WhatIf]
      [<CommonParameters>]
Remove-AzureRmADAppCredential
      [-Force]
      -KeyId <Guid>
      -ObjectId <String>
      [-Confirm]
      [-WhatIf]
      [<CommonParameters>]

Description

The Remove-AzureRmADAppCredential cmdlet can be used to remove a credential key from an application in the case of a compromise or as part of credential key rollover expiration. The application is identified by supplying either the object ID or AppId. The credential to be removed is identified by its key ID if an individual credential is to be removed or with an 'All' switch to delete all credentials associated with the application.

Examples

-------------------------- Example 1 --------------------------

PS E:\> Remove-AzureRmADAppCredential -ObjectId 7663d3fb-6f86-4352-9e6d-cf9d50d5ee82 -KeyId 9044423a-60a3-45ac-9ab1-09534157ebb

This command removes a credential key from an application. In this example, the key with Id "9044423a-60a3-45ac-9ab1-09534157ebb" will be removed from the application.

-------------------------- Example 2 --------------------------

PS E:\> Remove-AzureRmADAppCredential -ApplicationId 4589cd6b-3d79-4bb4-93b8-a0b99f3bfc58 -All

This command removes a credential key from an application. In this example, all credentials will be removed from the application associated with the applicationId "4589cd6b-3d79-4bb4-93b8-a0b99f3bfc58".

Required Parameters

-All

Switch to remove all the credentials associated with the application.

Type:SwitchParameter
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-ApplicationId

The id of the application to remove the credentials from.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-KeyId

Specifies the credential key to be removed. The key Ids for the application can be obtained using the Get-AzureRmADAppCredential cmdlet.

Type:Guid
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-ObjectId

The object id of the application to remove the credentials from.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False

Optional Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Force

Switch to delete credential without a confirmation.

Type:SwitchParameter
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-WhatIf
Type:SwitchParameter
Aliases:wi
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False