Gallery › Stream Analytics › Azure built-in policies
Azure Stream Analytics jobs should use customer-managed keys to encrypt data
Converted Policy Audit Deny Disabled Mode Indexed Version 1.1.0
Use customer-managed keys when you want to securely store any metadata and private data assets of your Stream Analytics jobs in your storage account. This gives you total control over how your Stream Analytics data is encrypted.
ConvertTo-Bylaw converted this policy, and proved that the file compiles back to the same definition.
Azure Policy JSONCMK_Audit.json · 53 lines
{
"properties": {
"displayName": "Azure Stream Analytics jobs should use customer-managed keys to encrypt data",
"policyType": "BuiltIn",
"mode": "Indexed",
"description": "Use customer-managed keys when you want to securely store any metadata and private data assets of your Stream Analytics jobs in your storage account. This gives you total control over how your Stream Analytics data is encrypted.",
"metadata": {
"version": "1.1.0",
"category": "Stream Analytics"
},
"version": "1.1.0",
"parameters": {
"effect": {
"type": "String",
"metadata": {
"displayName": "Effect",
"description": "The desired effect of the policy."
},
"allowedValues": [
"audit",
"Audit",
"deny",
"Deny",
"disabled",
"Disabled"
],
"defaultValue": "Audit"
}
},
"policyRule": {
"if": {
"allOf": [
{
"field": "Microsoft.StreamAnalytics/streamingJobs/contentStoragePolicy",
"equals": "SystemAccount"
},
{
"field": "type",
"equals": "Microsoft.StreamAnalytics/streamingJobs"
}
]
},
"then": {
"effect": "[parameters('effect')]"
}
},
"versions": [
"1.1.0"
]
},
"id": "/providers/Microsoft.Authorization/policyDefinitions/87ba29ef-1ab3-4d82-b763-87fcd4f531f7",
"name": "87ba29ef-1ab3-4d82-b763-87fcd4f531f7"
}Bylaw87ba29ef-1ab3-4d82-b763-87fcd4f531f7.bylaw.ps1 · 28 lines
# Converted from CMK_Audit.json by ConvertTo-Bylaw.
Policy '87ba29ef-1ab3-4d82-b763-87fcd4f531f7' {
Properties @{
DisplayName = 'Azure Stream Analytics jobs should use customer-managed keys to encrypt data'
Description = 'Use customer-managed keys when you want to securely store any metadata and private data assets of your Stream Analytics jobs in your storage account. This gives you total control over how your Stream Analytics data is encrypted.'
Version = '1.1.0'
Category = 'Stream Analytics'
PolicyVersion = '1.1.0'
Mode = 'Indexed'
}
Parameter Effect @{
AllowedValues = @('audit', 'Audit', 'deny', 'Deny', 'disabled', 'Disabled')
Default = 'Audit'
DisplayName = 'Effect'
Description = 'The desired effect of the policy.'
}
Resource 'Microsoft.StreamAnalytics/streamingJobs' {
Require 'contentStoragePolicy is not SystemAccount' {
Field contentStoragePolicy | Must -Not -Be 'SystemAccount' -IfPresent
}
}
Effect (Param Effect)
}Source: built-in-policies/policyDefinitions/Stream Analytics/CMK_Audit.json in Azure/azure-policy, under the MIT licence.
Bylaw