概述
Azure 磁盘加密使用 BitLocker 在运行 Windows 的 Azure 虚拟机上提供完全磁盘加密。 此解决方案与 Azure Key Vault 集成,以管理 Key Vault 订阅中的磁盘加密密钥和机密。
注释
尝试 VM 辅助,以便更快地进行诊断。 建议运行 VM assist for Windows 或 VM assist for Linux。 这些基于脚本的诊断工具可帮助你识别影响 Azure VM 来宾代理和整体 VM 运行状况的常见问题。
先决条件
有关先决条件的完整列表,请参阅适用于 Windows VM 的 Azure 磁盘加密,重点关注以下部分:
扩展架构
Azure 磁盘加密 (ADE) 的扩展架构有两个版本:
- v2.2 - 推荐的较新架构,它不使用 Microsoft Entra 属性。
- v1.1 - 需要 Microsoft Entra 属性的较旧架构。
若要选择目标架构,需要将 typeHandlerVersion 属性设置为要使用的架构版本。
架构 v2.2:没有 Microsoft Entra ID(推荐)
推荐对所有新 VM 使用 v2.2 架构,此架构不需要 Microsoft Entra 属性。
{
"type": "extensions",
"name": "[name]",
"apiVersion": "2019-07-01",
"location": "[location]",
"properties": {
"publisher": "Microsoft.Azure.Security",
"type": "AzureDiskEncryption",
"typeHandlerVersion": "2.2",
"autoUpgradeMinorVersion": true,
"settings": {
"EncryptionOperation": "[encryptionOperation]",
"KeyEncryptionAlgorithm": "[keyEncryptionAlgorithm]",
"KeyVaultURL": "[keyVaultURL]",
"KeyVaultResourceId": "[keyVaultResourceID]",
"KeyEncryptionKeyURL": "[keyEncryptionKeyURL]",
"KekVaultResourceId": "[kekVaultResourceID]",
"SequenceVersion": "sequenceVersion]",
"VolumeType": "[volumeType]"
}
}
}
架构 v1.1:使用 Microsoft Entra ID
1.1 版架构需要 aadClientID 和 aadClientSecret 或 AADClientCertificate,建议不要用于新 VM。
使用 aadClientSecret:
{
"type": "extensions",
"name": "[name]",
"apiVersion": "2019-07-01",
"location": "[location]",
"properties": {
"protectedSettings": {
"AADClientSecret": "[aadClientSecret]"
},
"publisher": "Microsoft.Azure.Security",
"type": "AzureDiskEncryption",
"typeHandlerVersion": "1.1",
"settings": {
"AADClientID": "[aadClientID]",
"EncryptionOperation": "[encryptionOperation]",
"KeyEncryptionAlgorithm": "[keyEncryptionAlgorithm]",
"KeyVaultURL": "[keyVaultURL]",
"KeyVaultResourceId": "[keyVaultResourceID]",
"KeyEncryptionKeyURL": "[keyEncryptionKeyURL]",
"KekVaultResourceId": "[kekVaultResourceID]",
"SequenceVersion": "sequenceVersion]",
"VolumeType": "[volumeType]"
}
}
}
使用 AADClientCertificate:
{
"type": "extensions",
"name": "[name]",
"apiVersion": "2019-07-01",
"location": "[location]",
"properties": {
"protectedSettings": {
"AADClientCertificate": "[aadClientCertificate]"
},
"publisher": "Microsoft.Azure.Security",
"type": "AzureDiskEncryption",
"typeHandlerVersion": "1.1",
"settings": {
"AADClientID": "[aadClientID]",
"EncryptionOperation": "[encryptionOperation]",
"KeyEncryptionAlgorithm": "[keyEncryptionAlgorithm]",
"KeyVaultURL": "[keyVaultURL]",
"KeyVaultResourceId": "[keyVaultResourceID]",
"KeyEncryptionKeyURL": "[keyEncryptionKeyURL]",
"KekVaultResourceId": "[kekVaultResourceID]",
"SequenceVersion": "sequenceVersion]",
"VolumeType": "[volumeType]"
}
}
}
属性值
注意:所有值均区分大小写。
| Name | 值/示例 | 数据类型 |
|---|---|---|
| apiVersion | 2019-07-01 | date |
| 发布服务器 | Microsoft.Azure.Security | 字符串 |
| 类型 | AzureDiskEncryption | 字符串 |
| typeHandlerVersion | 2.2, 1.1 | 字符串 |
| (1.1 架构)AADClientID | xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx | guid |
| (1.1 架构)AADClientSecret | 密码 | 字符串 |
| (1.1 架构)AADClientCertificate | 指纹 | 字符串 |
| EncryptionOperation | EnableEncryption | 字符串 |
| (可选 - 默认 RSA-OAEP)KeyEncryptionAlgorithm | “RSA-OAEP”、“RSA-OAEP-256”、“RSA1_5” | 字符串 |
| KeyVaultURL | 网址 | 字符串 |
| KeyVaultResourceId | 网址 | 字符串 |
| (可选)KeyEncryptionKeyURL | 网址 | 字符串 |
| (可选)KekVaultResourceId | 网址 | 字符串 |
| (可选)SequenceVersion | uniqueidentifier | 字符串 |
| VolumeType | OS、数据、全部 | 字符串 |
模板部署
有关基于架构 v2.2 的模板部署的示例,请参阅 Azure 快速入门模板 encrypt-running-windows-vm-without-aad。
有关基于架构 v1.1 的模板部署示例,请参阅 Azure 快速启动模板 encrypt-running-windows-vm。
注释
另外,如果将 VolumeType 参数设置为 All,则仅当数据磁盘已正确格式化时才会对其进行加密。
故障排除和支持
Troubleshoot
有关故障排除,请参阅 Azure 磁盘加密故障排除指南。
Support
如果对本文中的任何观点存在疑问,可以联系 Azure 支持上的 Azure 专家。
或者,也可以提出 Azure 支持事件。 转到 Azure 支持站点 并提交请求。 有关使用 Azure 支持的信息,请阅读 世纪互联 Azure 支持常见问题解答。
后续步骤
- 有关扩展的详细信息,请参阅适用于 Windows 的虚拟机扩展和功能。
- 有关适用于 Windows 的 Azure 磁盘加密的详细信息,请参阅 Windows 虚拟机。