如何管理法律標籤
在本文中,您將了解如何管理 Azure Data Manager for Energy 執行個體中的法律標籤。 在 Azure Data Manager for Energy 執行個體中,法律標籤指的是代表資料法律狀態的實體。 法律標記指的是控管如何擷取和取用資料的屬性集合。 資料需要法律標籤,才能內嵌到 Azure Data Manager for Energy 執行個體中。 您也需要法律標籤,才能從 Azure Data Manager for Energy 執行個體取用資料。 法律標籤會在資料分割區的層級上個別定義。
在 Azure Data Manager for Energy 執行個體中,權利服務會定義特定使用者 (們) 的資料存取權,而法律標籤則會定義多位使用者的整體資料存取權。 使用者可能擁有管理資料分割區內資料的權限,但在滿足特定法律需求之前,他們可能無法這麼做。
建立法律標籤
在 Azure Cloud Bash 中執行下列 curl 命令,為 Azure Data Manager for Energy 執行個體中的指定資料分割區建立法律標籤。
curl --location --request POST 'https://<URI>/api/legal/v1/legaltags' \
--header 'data-partition-id: <data-partition-id>' \
--header 'Authorization: Bearer <access_token>' \
--header 'Content-Type: application/json' \
--data-raw '{
"name": "<legal-tag-name>",
"description": "<legal-tag-description>",
"properties": {
"contractId": "<contract-id>",
"countryOfOrigin": ["<country-of-origin>"],
"dataType": "<data-type>",
"expirationDate": "<expiration-ID>",
"exportClassification": "<export-classification>",
"originator": "<originator>",
"personalData": "<personal-data>",
"securityClassification": "Public"
}
}'
範例要求
設想一個名為 "medstest" 的 Azure Data Manager for Energy 執行個體,其資料分割區名為 "dp1"
curl --location --request POST 'https://medstest.energy.azure.com/api/legal/v1/legaltags' \
--header 'data-partition-id: medstest-dp1' \
--header 'Authorization: Bearer eyxxxxxxx.........................' \
--header 'Content-Type: application/json' \
--data-raw '{
"name": "medstest-dp1-legal-tag",
"description": "Azure Data Manager for Energy Legal Tag",
"properties": {
"contractId": "A1234",
"countryOfOrigin": ["US"],
"dataType": "Public Domain Data",
"expirationDate": "2099-01-25",
"exportClassification": "EAR99",
"originator": "MyCompany",
"personalData": "No Personal Data",
"securityClassification": "Public"
}
}'
範例回覆
{
"name": "medsStest-dp1-legal-tag",
"description": "Azure Data Manager for Energy Legal Tag",
"properties": {
"countryOfOrigin": [
"US"
],
"contractId": "A1234",
"expirationDate": "2099-01-25",
"originator": "MyCompany",
"dataType": "Public Domain Data",
"securityClassification": "Public",
"personalData": "No Personal Data",
"exportClassification": "EAR99"
}
}
來源國應遵循 ISO Alpha2 格式。
建立法律標籤 API 將資料分割區的識別碼內部附加至法律標籤名稱 (如果尚未附加)。 例如,如果要求的名稱為:legal-tag
,則建立的法律標籤名稱會是 <instancename>-<data-partition-id>-legal-tag
curl --location --request POST 'https://medstest.energy.azure.com/api/legal/v1/legaltags' \
--header 'data-partition-id: medstest-dp1' \
--header 'Authorization: Bearer eyxxxxxxx.........................' \
--header 'Content-Type: application/json' \
--data-raw '{
"name": "legal-tag",
"description": "Azure Data Manager for Energy Legal Tag",
"properties": {
"contractId": "A1234",
"countryOfOrigin": ["US"],
"dataType": "Public Domain Data",
"expirationDate": "2099-01-25",
"exportClassification": "EAR99",
"originator": "MyCompany",
"personalData": "No Personal Data",
"securityClassification": "Public"
}
}'
在範例回應中,資料分割區的識別碼會附加至法律標籤名稱,而該範例回應將會是:
{
"name": "medstest-dp1-legal-tag",
"description": "Azure Data Manager for Energy Legal Tag",
"properties": {
"countryOfOrigin": [
"US"
],
"contractId": "A1234",
"expirationDate": "2099-01-25",
"originator": "MyCompany",
"dataType": "Public Domain Data",
"securityClassification": "Public",
"personalData": "No Personal Data",
"exportClassification": "EAR99"
}
}
取得法律標籤
在 Azure Cloud Bash 中執行下列 curl 命令以取得與 Azure Data Manager for Energy 執行個體的資料分割區相關聯的法律標籤。
curl --location --request GET 'https://<URI>/api/legal/v1/legaltags/<legal-tag-name>' \
--header 'data-partition-id: <data-partition-id>' \
--header 'Authorization: Bearer <access_token>'
範例要求
設想一個名為 "medstest" 的 Azure Data Manager for Energy 執行個體,其資料分割區名為 "dp1"
curl --location --request GET 'https://medstest.energy.azure.com/api/legal/v1/legaltags/medstest-dp1-legal-tag' \
--header 'data-partition-id: medstest-dp1' \
--header 'Authorization: Bearer eyxxxxxxx.........................'
範例回應
{
"name": "medstest-dp1-legal-tag",
"description": "Azure Data Manager for Energy Legal Tag",
"properties": {
"countryOfOrigin": [
"US"
],
"contractId": "A1234",
"expirationDate": "2099-01-25",
"originator": "MyCompany",
"dataType": "Public Domain Data",
"securityClassification": "Public",
"personalData": "No Personal Data",
"exportClassification": "EAR99"
}
}
下一步
意見反映
https://aka.ms/ContentUserFeedback。
即將推出:我們會在 2024 年淘汰 GitHub 問題,並以全新的意見反應系統取代並作為內容意見反應的渠道。 如需更多資訊,請參閱:提交及檢視以下的意見反映: