New-AzDataBoxKeyEncryptionKeyObject

Create an in-memory object for KeyEncryptionKey.

Syntax

New-AzDataBoxKeyEncryptionKeyObject
   -KekType <KekType>
   [-IdentityProperty <IIdentityProperties>]
   [-KekUrl <String>]
   [-KekVaultResourceId <String>]
   [<CommonParameters>]

Description

Create an in-memory object for KeyEncryptionKey.

Examples

Example 1: Create a in-memory object for KeyEncryptionKey

New-AzDataBoxKeyEncryptionKeyObject -KekType "CustomerManaged" -IdentityProperty @{Type = "UserAssigned"; UserAssignedResourceId = "/subscriptions/SubscriptionId/resourceGroups/resourceGroupName/providers/Microsoft.ManagedIdentity/userAssignedIdentities/identityName"} -KekUrl "keyIdentifier" -KekVaultResourceId "/subscriptions/SubscriptionId/resourceGroups/resourceGroupName/providers/Microsoft.KeyVault/vaults/keyVaultName"

KekType         KekUrl                                           KekVaultResourceId
-------         ------                                           ------------------
CustomerManaged keyIdentifier /subscriptions/SubscriptionId/resourceGroups/resourceGroupName/providers/Microsoft.KeyVault/vaults/keyVaultName

Create a in-memory object for KeyEncryptionKey

Parameters

-IdentityProperty

Managed identity properties used for key encryption. To construct, see NOTES section for IDENTITYPROPERTY properties and create a hash table.

Type:IIdentityProperties
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-KekType

Type of encryption key used for key encryption.

Type:KekType
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-KekUrl

Key encryption key. It is required in case of Customer managed KekType.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-KekVaultResourceId

Kek vault resource id. It is required in case of Customer managed KekType.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

Outputs

KeyEncryptionKey