Gallery › Healthcare APIs › Azure built-in policies
DICOM Service should use a customer-managed key to encrypt data at rest
Converted Policy Audit Disabled Mode Indexed Version 1.0.0
Use a customer-managed key to control the encryption at rest of the data stored in Azure Health Data Services DICOM Service when this is a regulatory or compliance requirement. Customer-managed keys also deliver double encryption by adding a second layer of encryption on top of the default one done with service-managed keys.
ConvertTo-Bylaw converted this policy, and proved that the file compiles back to the same definition.
Azure Policy JSONDICOM_Service_CMK_Enabled.json · 57 lines
{
"properties": {
"displayName": "DICOM Service should use a customer-managed key to encrypt data at rest",
"policyType": "BuiltIn",
"mode": "Indexed",
"description": "Use a customer-managed key to control the encryption at rest of the data stored in Azure Health Data Services DICOM Service when this is a regulatory or compliance requirement. Customer-managed keys also deliver double encryption by adding a second layer of encryption on top of the default one done with service-managed keys.",
"metadata": {
"version": "1.0.0",
"category": "Healthcare APIs"
},
"version": "1.0.0",
"parameters": {
"effect": {
"type": "String",
"metadata": {
"displayName": "Effect",
"description": "Enable or disable the execution of the policy"
},
"allowedValues": [
"Audit",
"Disabled"
],
"defaultValue": "Audit"
}
},
"policyRule": {
"if": {
"allOf": [
{
"field": "type",
"equals": "Microsoft.HealthcareApis/workspaces/dicomservices"
},
{
"anyOf": [
{
"field": "Microsoft.HealthcareApis/workspaces/dicomservices/encryption.customerManagedKeyEncryption.keyEncryptionKeyUrl",
"exists": "false"
},
{
"field": "Microsoft.HealthcareApis/workspaces/dicomservices/encryption.customerManagedKeyEncryption.keyEncryptionKeyUrl",
"equals": ""
}
]
}
]
},
"then": {
"effect": "[parameters('effect')]"
}
},
"versions": [
"1.0.0"
]
},
"id": "/providers/Microsoft.Authorization/policyDefinitions/14961b63-a1eb-4378-8725-7e84ca8db0e6",
"name": "14961b63-a1eb-4378-8725-7e84ca8db0e6"
}Bylaw14961b63-a1eb-4378-8725-7e84ca8db0e6.bylaw.ps1 · 32 lines
# Converted from DICOM_Service_CMK_Enabled.json by ConvertTo-Bylaw.
Policy '14961b63-a1eb-4378-8725-7e84ca8db0e6' {
Properties @{
DisplayName = 'DICOM Service should use a customer-managed key to encrypt data at rest'
Description = 'Use a customer-managed key to control the encryption at rest of the data stored in Azure Health Data Services DICOM Service when this is a regulatory or compliance requirement. Customer-managed keys also deliver double encryption by adding a second layer of encryption on top of the default one done with service-managed keys.'
Version = '1.0.0'
Category = 'Healthcare APIs'
PolicyVersion = '1.0.0'
Mode = 'Indexed'
}
Parameter Effect @{
AllowedValues = @('Audit', 'Disabled')
Default = 'Audit'
DisplayName = 'Effect'
Description = 'Enable or disable the execution of the policy'
}
Resource 'Microsoft.HealthcareApis/workspaces/dicomservices' {
Require 'encryption.customerManagedKeyEncryption.keyEncryptionKeyUrl exists' {
Field encryption.customerManagedKeyEncryption.keyEncryptionKeyUrl | Must -Exist
}
Require 'encryption.customerManagedKeyEncryption.keyEncryptionKeyUrl is not' {
Field encryption.customerManagedKeyEncryption.keyEncryptionKeyUrl | Must -Not -Be '' -IfPresent
}
}
Effect (Param Effect)
}Source: built-in-policies/policyDefinitions/Healthcare APIs/DICOM_Service_CMK_Enabled.json in Azure/azure-policy, under the MIT licence.
Bylaw