diff --git a/src/KeyVault/KeyVault/ChangeLog.md b/src/KeyVault/KeyVault/ChangeLog.md index ad044dcb279b..7a4f12cd594b 100644 --- a/src/KeyVault/KeyVault/ChangeLog.md +++ b/src/KeyVault/KeyVault/ChangeLog.md @@ -19,7 +19,7 @@ --> ## Upcoming Release * Formatted the output of Azure Key Vault certificate in removed state. [#24333] -* [Upcoming Breaking Change] Added breaking change warning message for parameter `EnableRbacAuthorization` of `New-AzKeyVault`. +* [Upcoming Breaking Change] Added breaking change warning message for parameter `EnableRbacAuthorization` of `New-AzKeyVault` and `Update-AzKeyVault`. - RBAC will be enabled by default during the process of key vault creation. To disable RBAC authorization, please use parameter 'DisableRbacAuthorization'. - Parameter `EnableRbacAuthorization` is expected to be removed in Az.KeyVault 6.0.0 and Az 12.0.0. - Parameter `EnableRbacAuthorization` is expected to be replaced by `DisableRbacAuthorization`. diff --git a/src/KeyVault/KeyVault/Commands/UpdateAzureKeyVault.cs b/src/KeyVault/KeyVault/Commands/UpdateAzureKeyVault.cs index ce5552076f54..6a6ea4b75588 100644 --- a/src/KeyVault/KeyVault/Commands/UpdateAzureKeyVault.cs +++ b/src/KeyVault/KeyVault/Commands/UpdateAzureKeyVault.cs @@ -15,6 +15,7 @@ using Microsoft.Azure.Commands.KeyVault.Models; using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters; using Microsoft.Azure.Management.Internal.Resources.Utilities.Models; +using Microsoft.WindowsAzure.Commands.Common.CustomAttributes; using Microsoft.WindowsAzure.Commands.Utilities.Common; using System; using System.Collections; @@ -51,6 +52,7 @@ public class UpdateTopLevelResourceCommand : KeyVaultManagementCmdletBase [Parameter(Mandatory = false, HelpMessage = "Enable the purge protection functionality for this key vault. Once enabled it cannot be disabled. It requires soft-delete to be turned on.")] public SwitchParameter EnablePurgeProtection { get; set; } + [CmdletParameterBreakingChangeWithVersion(nameof(EnableRbacAuthorization), "12.0.0", "6.0.0", ReplaceMentCmdletParameterName = "DisableRbacAuthorization", ChangeDescription = "RBAC will be enabled by default during the process of key vault creation. To disable RBAC authorization, please use parameter 'DisableRbacAuthorization'.")] [Parameter(Mandatory = false, HelpMessage = "Enable or disable this key vault to authorize data actions by Role Based Access Control (RBAC).")] public bool? EnableRbacAuthorization { get; set; }