Microsoft Azure 證明 是用於證明受信任執行環境 (TEE) 的解決方案。 本快速指南著重於部署 Azure Resource Manager 範本(ARM 範本)來建立 Microsoft Azure 證明政策。
Azure Resource Manager 範本是 JavaScript 物件表示法 (JSON) 檔案,可定義專案的基礎結構和組態。 範本使用宣告式語法。 您可以描述預期的部署,而不需要撰寫程式設計命令順序來建立部署。
如果您的環境符合必要條件,而且您很熟悉 ARM 範本,請選取 [部署至 Azure] 按鈕。 範本會在 Azure 入口網站中開啟。
先決條件
如尚未擁有 Azure 訂用帳戶,請在開始之前先建立免費帳戶。
檢閱範本
本快速入門中使用的範本是來自 Azure 快速入門範本。
{
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"metadata": {
"_generator": {
"name": "bicep",
"version": "0.25.53.49325",
"templateHash": "1187521685481570330"
}
},
"parameters": {
"attestationProviderName": {
"type": "string",
"defaultValue": "[uniqueString(resourceGroup().name)]",
"metadata": {
"description": "Name of the Attestation provider. Must be between 3 and 24 characters in length and use numbers and lower-case letters only."
}
},
"location": {
"type": "string",
"defaultValue": "[resourceGroup().location]",
"metadata": {
"description": "Location for all resources."
}
},
"policySigningCertificates": {
"type": "string",
"defaultValue": ""
}
},
"variables": {
"PolicySigningCertificates": {
"PolicySigningCertificates": {
"keys": [
{
"kty": "RSA",
"use": "sig",
"x5c": [
"[parameters('policySigningCertificates')]"
]
}
]
}
}
},
"resources": [
{
"type": "Microsoft.Attestation/attestationProviders",
"apiVersion": "2021-06-01",
"name": "[parameters('attestationProviderName')]",
"location": "[parameters('location')]",
"properties": "[if(empty(parameters('policySigningCertificates')), json('{}'), variables('PolicySigningCertificates'))]"
}
],
"outputs": {
"attestationName": {
"type": "string",
"value": "[resourceId('Microsoft.Attestation/attestationProviders', parameters('attestationProviderName'))]"
},
"location": {
"type": "string",
"value": "[parameters('location')]"
},
"resourceGroupName": {
"type": "string",
"value": "[resourceGroup().name]"
},
"resourceId": {
"type": "string",
"value": "[resourceId('Microsoft.Attestation/attestationProviders', parameters('attestationProviderName'))]"
}
}
}
範本中定義的 Azure 資源:
- Microsoft.Attestation/attestationProviders
部署範本
選取以下影像來登入 Azure 並開啟範本。
選取或輸入下列值。
除非有特別指定,否則請使用預設值來建立證明供應商。
- 證明提供者名稱:選取 Azure 證明提供者的名稱。
- 位置:選取位置。 例如,美國中部。
- 標籤:選取位置。 例如,美國中部。
選取 購買。 成功部署證明資源之後,您會收到通知。
Azure 入口網站用於部署範本。 除了 Azure 入口網站以外,您也可以使用 Azure PowerShell、Azure CLI 和 REST API。 若要了解其他部署方法,請參閱部署範本。
檢閱已部署的資源
您可以使用 Azure 入口網站 來檢查證明資源。
清理資源
其他 Azure 證明會以本快速入門為基礎。 如果您打算繼續進行後續的快速入門和教學課程,您可以讓這些資源留在原處。
不再需要時,請刪除資源群組,這會刪除證明資源。 若要使用 Azure CLI 或 Azure PowerShell 刪除資源群組:
echo "Enter the Resource Group name:" &&
read resourceGroupName &&
az group delete --name $resourceGroupName &&
echo "Press [ENTER] to continue ..."
後續步驟
在本快速入門中,您已使用 ARM 範本建立證明資源,並驗證部署。 若要深入瞭解 Azure 證明,請參閱 Azure 證明概觀。