Skip to content

Commit c8f00e9

Browse files
committed
update
1 parent 678868b commit c8f00e9

File tree

6 files changed

+43
-14
lines changed

6 files changed

+43
-14
lines changed

articles/key-vault/certificates/quick-create-cli.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,9 @@ In this quickstart, you create a key vault in Azure Key Vault with Azure CLI. Az
2626

2727
## Create a key vault
2828

29-
[!INCLUDE [Create a key vault](../../../includes/key-vault-cli-kv-creation.md)]
29+
[!INCLUDE [Create a key vault](../../../includes/key-vault/kv-creation-cli.md)]
30+
31+
##
3032

3133
## Add a certificate to Key Vault
3234

articles/key-vault/general/rbac-guide.md

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -21,20 +21,17 @@ ms.author: mbaldwin
2121
2222
Azure role-based access control (Azure RBAC) is an authorization system built on [Azure Resource Manager](../../azure-resource-manager/management/overview.md) that provides centralized access management of Azure resources.
2323

24-
Azure RBAC allows users to manage Key, Secrets, and Certificates permissions. It provides one place to manage all permissions across all key vaults.
24+
Azure RBAC allows users to manage keys, secrets, and certificates permissions, and provides one place to manage all permissions across all key vaults.
2525

26-
The Azure RBAC model allows users to set permissions on different scope levels: management group, subscription, resource group, or individual resources. Azure RBAC for key vault also allows users to have separate permissions on individual keys, secrets, and certificates
26+
The Azure RBAC model allows users to set permissions on different scope levels: management group, subscription, resource group, or individual resources. Azure RBAC for key vault also allows users to have separate permissions on individual keys, secrets, and certificates.
2727

2828
For more information, see [Azure role-based access control (Azure RBAC)](../../role-based-access-control/overview.md).
2929

3030
## Best Practices for individual keys, secrets, and certificates role assignments
3131

32-
Our recommendation is to use a vault per application per environment
33-
(Development, Pre-Production, and Production) with roles assigned at Key Vault scope.
32+
Our recommendation is to use a vault per application per environment (Development, Pre-Production, and Production) with roles assigned at the key vault scope.
3433

35-
Assigning roles on individual keys, secrets and certificates should be avoided. Exceptions to general guidance:
36-
37-
- Scenarios where individual secrets must be shared between multiple applications, for example, one application needs to access data from the other application
34+
Assigning roles on individual keys, secrets and certificates should be avoided. An exception is a scenario where individual secrets must be shared between multiple applications; for example, where one application needs to access data from another application.
3835

3936
More about Azure Key Vault management guidelines, see:
4037

@@ -69,7 +66,7 @@ For more information about Azure built-in roles definitions, see [Azure built-in
6966

7067
## Using Azure RBAC secret, key, and certificate permissions with Key Vault
7168

72-
The new Azure RBAC permission model for key vault provides alternative to the vault access policy permissions model.
69+
The new Azure RBAC permission model for key vault provides alternative to the vault access policy permissions model.
7370

7471
### Prerequisites
7572

@@ -80,7 +77,7 @@ To manage role assignments, you must have `Microsoft.Authorization/roleAssignmen
8077
### Enable Azure RBAC permissions on Key Vault
8178

8279
> [!NOTE]
83-
> Changing permission model requires unrestricted 'Microsoft.Authorization/roleAssignments/write' permission, which is part of [Owner](../../role-based-access-control/built-in-roles.md#owner) and [User Access Administrator](../../role-based-access-control/built-in-roles.md#user-access-administrator) roles. Classic subscription administrator roles like 'Service Administrator' and 'Co-Administrator', or restricted 'Key Vault Data Access Administrator' cannot be used to change permission model.
80+
> Changing the permission model requires unrestricted 'Microsoft.Authorization/roleAssignments/write' permission, which is part of the [Owner](../../role-based-access-control/built-in-roles.md#owner) and [User Access Administrator](../../role-based-access-control/built-in-roles.md#user-access-administrator) roles. Classic subscription administrator roles like 'Service Administrator' and 'Co-Administrator', or restricted 'Key Vault Data Access Administrator' cannot be used to change permission model.
8481
8582
1. Enable Azure RBAC permissions on new key vault:
8683

@@ -95,8 +92,8 @@ To manage role assignments, you must have `Microsoft.Authorization/roleAssignmen
9592
9693
### Assign role
9794

98-
> [!Note]
99-
> It's recommended to use the unique role ID instead of the role name in scripts. Therefore, if a role is renamed, your scripts would continue to work. In this document role name is used only for readability.
95+
> [!NOTE]
96+
> It's recommended to use the unique role ID instead of the role name in scripts. Therefore, if a role is renamed, your scripts would continue to work. In this document role name is used for readability.
10097
10198
# [Azure CLI](#tab/azure-cli)
10299

articles/key-vault/general/tutorial-net-create-vault-azure-web-app.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ To complete this tutorial, you need:
3535
* [Azure Key Vault.](./overview.md) You can create a key vault by using the [Azure portal](quick-create-portal.md), the [Azure CLI](quick-create-cli.md), or [Azure PowerShell](quick-create-powershell.md).
3636
* A Key Vault [secret](../secrets/about-secrets.md). You can create a secret by using the [Azure portal](../secrets/quick-create-portal.md), [PowerShell](../secrets/quick-create-powershell.md), or the [Azure CLI](../secrets/quick-create-cli.md).
3737

38-
If you already have your web application deployed in Azure App Service, you can skip to [configure web app access to a key vault](#create-and-assign-a-managed-identity) and [modify web application code](#modify-the-app-to-access-your-key-vault) sections.
38+
If you already have your web application deployed in Azure App Service, you can skip to [configure web app access to a key vault](#configure-the-web-app-to-connect-to-key-vault) and [modify web application code](#modify-the-app-to-access-your-key-vault) sections.
3939

4040
## Create a .NET Core app
4141
In this step, you'll set up the local .NET Core project.

includes/key-vault-quickstart-rbac.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
---
2+
author: msmbaldwin
3+
ms.service: key-vault
4+
ms.topic: include
5+
ms.date: 04/04/2024
6+
ms.author: msmbaldwin
7+
8+
# Used by articles that show how to assign a Key Vault access policy
9+
10+
---
11+
12+
### [Azure CLI](#tab/azure-cli)
13+
14+
To grant your application permissions to your key vault through Role-Based Access Control (RBAC), assign a role using the Azure CLI command [az role assignment create](/cli/azure/role/assignment#az-role-assignment-create).
15+
16+
```azurecli
17+
az role assignment create --role "Key Vault Secrets User" --assignee "<app-id>" --scope "/subscriptions/<subscription-id>/resourceGroups/<resource-group-name>/providers/Microsoft.KeyVault/vaults/<your-unique-keyvault-name>"
18+
```
19+
20+
### [Azure PowerShell](#tab/azure-powershell)
21+
22+
To grant your application permissions to your key vault through Role-Based Access Control (RBAC), assign a role using the Azure PowerShell cmdlet [New-AzRoleAssignment](/powershell/module/az.resources/new-azroleassignment).
23+
24+
```azurepowershell
25+
New-AzRoleAssignment -ObjectId "<app-id>" -RoleDefinitionName "Key Vault Secrets User" -Scope "/subscriptions/<subscription-id>/resourceGroups/<resource-group-name>/providers/Microsoft.KeyVault/vaults/<your-unique-keyvault-name>"
26+
```
27+
28+
---
29+
30+
Replace \<app-id\>, \<subscription-id\>, \<resource-group-name\> and \<your-unique-keyvault-name\> with your actual values. \<app-id\> is the Application (client) ID of your registered application in Azure AD.

includes/key-vault/key-vault-cli-kv-creation.md renamed to includes/key-vault/kv-creation-cli.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ Use the Azure CLI [az keyvault create](/cli/azure/keyvault#az-keyvault-create) c
2020
- The location: **EastUS**.
2121

2222
```azurecli
23-
az keyvault create --name "<your-unique-keyvault-name>" --resource-group "myResourceGroup" --location "EastUS"
23+
az keyvault create --name "<your-unique-keyvault-name>" --resource-group "myResourceGroup"
2424
```
2525

2626
The output of this command shows properties of the newly created key vault. Take note of these two properties:
File renamed without changes.

0 commit comments

Comments
 (0)