diff --git a/specification/security/resource-manager/Microsoft.Security/preview/2023-02-15-preview/examples/SensitivitySettings/GetSensitivitySettingsList_example.json b/specification/security/resource-manager/Microsoft.Security/preview/2023-02-15-preview/examples/SensitivitySettings/GetSensitivitySettingsList_example.json new file mode 100644 index 000000000000..ff7f7ab989bd --- /dev/null +++ b/specification/security/resource-manager/Microsoft.Security/preview/2023-02-15-preview/examples/SensitivitySettings/GetSensitivitySettingsList_example.json @@ -0,0 +1,86 @@ +{ + "parameters": { + "api-version": "2023-02-15-preview" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "id": "/providers/Microsoft.Security/sensitivitySettings", + "name": "current", + "type": "Microsoft.Security/sensitivitySettings", + "properties": { + "sensitiveInfoTypesIds": [ + "a98fde82-45b6-4b2c-afd0-ad579cd9f826", + "4d0d3eb6-619f-4c8c-810c-c16150c95278", + "0e9b3178-9678-47dd-a509-37222ca96b42", + "c5f9b9a1-2b9a-4a3a-8c5b-1f3d1d9d9c9b" + ], + "sensitivityThresholdLabelOrder": 1, + "mipInformation": { + "mipIntegrationStatus": "Ok", + "labels": [ + { + "name": "Public", + "id": "fdfb5435-124d-4651-a889-a4210fec6a77", + "order": 0 + }, + { + "name": "Confidential", + "id": "4c5447ec-f7f3-4345-a160-6a5850f2bf0c", + "order": 1 + }, + { + "name": "Highly Confidential", + "id": "f38ac75c-f42a-4c89-aa37-9c4e74101414", + "order": 2 + } + ], + "customInfoTypes": [ + { + "name": "User created custom info type 1", + "id": "c5f9b9a1-2b9a-4a3a-8c5b-1f3d1d9d9c9b", + "description": "Custom info type description" + }, + { + "name": "User created custom info type 2", + "id": "a4fee2b6-5618-404b-a5e7-aa377cd67543", + "description": "Custom info type description" + }, + { + "name": "User created custom info type 3", + "id": "a355f11e-f87d-4f48-8490-ecf0873325b5", + "description": "Custom info type description" + } + ], + "builtInInfoTypes": [ + { + "name": "Http Authorization Header", + "type": "Credentials", + "id": "4d0d3eb6-619f-4c8c-810c-c16150c95278" + }, + { + "name": "User Login Credentials", + "type": "Credentials", + "id": "a98fde82-45b6-4b2c-afd0-ad579cd9f826" + }, + { + "name": "Credit card number", + "type": "Finance", + "id": "50842eb7-edc8-4019-85dd-5a5c1f2bb085" + }, + { + "name": "EU debit card number", + "type": "Finance", + "id": "0e9b3178-9678-47dd-a509-37222ca96b42" + } + ] + } + } + } + ] + } + } + } +} diff --git a/specification/security/resource-manager/Microsoft.Security/preview/2023-02-15-preview/examples/SensitivitySettings/GetSensitivitySettings_example.json b/specification/security/resource-manager/Microsoft.Security/preview/2023-02-15-preview/examples/SensitivitySettings/GetSensitivitySettings_example.json new file mode 100644 index 000000000000..a179d93503fb --- /dev/null +++ b/specification/security/resource-manager/Microsoft.Security/preview/2023-02-15-preview/examples/SensitivitySettings/GetSensitivitySettings_example.json @@ -0,0 +1,82 @@ +{ + "parameters": { + "api-version": "2023-02-15-preview" + }, + "responses": { + "200": { + "body": { + "id": "/providers/Microsoft.Security/sensitivitySettings", + "name": "current", + "type": "Microsoft.Security/sensitivitySettings", + "properties": { + "sensitiveInfoTypesIds": [ + "a98fde82-45b6-4b2c-afd0-ad579cd9f826", + "4d0d3eb6-619f-4c8c-810c-c16150c95278", + "0e9b3178-9678-47dd-a509-37222ca96b42", + "c5f9b9a1-2b9a-4a3a-8c5b-1f3d1d9d9c9b" + ], + "sensitivityThresholdLabelOrder": 1, + "mipInformation": { + "mipIntegrationStatus": "Ok", + "labels": [ + { + "name": "Public", + "id": "fdfb5435-124d-4651-a889-a4210fec6a77", + "order": 0 + }, + { + "name": "Confidential", + "id": "4c5447ec-f7f3-4345-a160-6a5850f2bf0c", + "order": 1 + }, + { + "name": "Highly Confidential", + "id": "f38ac75c-f42a-4c89-aa37-9c4e74101414", + "order": 2 + } + ], + "customInfoTypes": [ + { + "name": "User created custom info type 1", + "id": "c5f9b9a1-2b9a-4a3a-8c5b-1f3d1d9d9c9b", + "description": "Custom info type description" + }, + { + "name": "User created custom info type 2", + "id": "a4fee2b6-5618-404b-a5e7-aa377cd67543", + "description": "Custom info type description" + }, + { + "name": "User created custom info type 3", + "id": "a355f11e-f87d-4f48-8490-ecf0873325b5", + "description": "Custom info type description" + } + ], + "builtInInfoTypes": [ + { + "name": "Http Authorization Header", + "type": "Credentials", + "id": "4d0d3eb6-619f-4c8c-810c-c16150c95278" + }, + { + "name": "User Login Credentials", + "type": "Credentials", + "id": "a98fde82-45b6-4b2c-afd0-ad579cd9f826" + }, + { + "name": "Credit card number", + "type": "Finance", + "id": "50842eb7-edc8-4019-85dd-5a5c1f2bb085" + }, + { + "name": "EU debit card number", + "type": "Finance", + "id": "0e9b3178-9678-47dd-a509-37222ca96b42" + } + ] + } + } + } + } + } +} diff --git a/specification/security/resource-manager/Microsoft.Security/preview/2023-02-15-preview/examples/SensitivitySettings/PutSensitivitySettings_example.json b/specification/security/resource-manager/Microsoft.Security/preview/2023-02-15-preview/examples/SensitivitySettings/PutSensitivitySettings_example.json new file mode 100644 index 000000000000..e26f1d1329e1 --- /dev/null +++ b/specification/security/resource-manager/Microsoft.Security/preview/2023-02-15-preview/examples/SensitivitySettings/PutSensitivitySettings_example.json @@ -0,0 +1,92 @@ +{ + "parameters": { + "api-version": "2023-02-15-preview", + "sensitivitySettings": { + "sensitiveInfoTypesIds": [ + "f2f8a7a1-28c0-404b-9ab4-30a0a7af18cb", + "b452f22b-f87d-4f48-8490-ecf0873325b5", + "d59ee8b6-2618-404b-a5e7-aa377cd67543" + ], + "sensitivityThresholdLabelOrder": 2, + "sensitivityThresholdLabelId": "f2f8a7a1-28c0-404b-9ab4-30a0a7af18cb" + } + }, + "responses": { + "200": { + "description": "OK", + "body": { + "id": "/providers/Microsoft.Security/sensitivitySettings", + "name": "current", + "type": "Microsoft.Security/sensitivitySettings", + "properties": { + "sensitiveInfoTypesIds": [ + "a98fde82-45b6-4b2c-afd0-ad579cd9f826", + "4d0d3eb6-619f-4c8c-810c-c16150c95278", + "0e9b3178-9678-47dd-a509-37222ca96b42", + "c5f9b9a1-2b9a-4a3a-8c5b-1f3d1d9d9c9b" + ], + "sensitivityThresholdLabelOrder": 2, + "mipInformation": { + "mipIntegrationStatus": "Ok", + "labels": [ + { + "name": "Public", + "id": "fdfb5435-124d-4651-a889-a4210fec6a77", + "order": 0 + }, + { + "name": "Confidential", + "id": "4c5447ec-f7f3-4345-a160-6a5850f2bf0c", + "order": 1 + }, + { + "name": "Highly Confidential", + "id": "f38ac75c-f42a-4c89-aa37-9c4e74101414", + "order": 2 + } + ], + "customInfoTypes": [ + { + "name": "User created custom info type 1", + "id": "c5f9b9a1-2b9a-4a3a-8c5b-1f3d1d9d9c9b", + "description": "Custom info type description" + }, + { + "name": "User created custom info type 2", + "id": "a4fee2b6-5618-404b-a5e7-aa377cd67543", + "description": "Custom info type description" + }, + { + "name": "User created custom info type 3", + "id": "a355f11e-f87d-4f48-8490-ecf0873325b5", + "description": "Custom info type description" + } + ], + "builtInInfoTypes": [ + { + "name": "Http Authorization Header", + "type": "Credentials", + "id": "4d0d3eb6-619f-4c8c-810c-c16150c95278" + }, + { + "name": "User Login Credentials", + "type": "Credentials", + "id": "a98fde82-45b6-4b2c-afd0-ad579cd9f826" + }, + { + "name": "Credit card number", + "type": "Finance", + "id": "50842eb7-edc8-4019-85dd-5a5c1f2bb085" + }, + { + "name": "EU debit card number", + "type": "Finance", + "id": "0e9b3178-9678-47dd-a509-37222ca96b42" + } + ] + } + } + } + } + } +} diff --git a/specification/security/resource-manager/Microsoft.Security/preview/2023-02-15-preview/sensitivitySettings.json b/specification/security/resource-manager/Microsoft.Security/preview/2023-02-15-preview/sensitivitySettings.json new file mode 100644 index 000000000000..57c2e42cafc9 --- /dev/null +++ b/specification/security/resource-manager/Microsoft.Security/preview/2023-02-15-preview/sensitivitySettings.json @@ -0,0 +1,328 @@ +{ + "swagger": "2.0", + "info": { + "title": "Data Sensitivity Settings", + "description": "API spec for Microsoft.Security Data Sensitivity Settings", + "version": "2023-02-15-preview" + }, + "host": "management.azure.com", + "schemes": [ + "https" + ], + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "security": [ + { + "azure_auth": [ + "user_impersonation" + ] + } + ], + "securityDefinitions": { + "azure_auth": { + "type": "oauth2", + "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", + "flow": "implicit", + "description": "Azure Active Directory OAuth2 Flow", + "scopes": { + "user_impersonation": "impersonate your user account" + } + } + }, + "paths": { + "/providers/Microsoft.Security/sensitivitySettings/current": { + "put": { + "tags": [ + "sensitivitySettings" + ], + "description": "Updates data sensitivity settings for sensitive data discovery", + "operationId": "UpdateSensitivitySettings", + "parameters": [ + { + "$ref": "../../../common/v1/types.json#/parameters/ApiVersion" + }, + { + "in": "body", + "name": "sensitivitySettings", + "description": "The data sensitivity settings to update", + "required": true, + "schema": { + "$ref": "#/definitions/UpdateSensitivitySettingsRequest" + } + } + ], + "responses": { + "200": { + "description": "Success of the sensitivity settings update", + "schema": { + "$ref": "#/definitions/GetSensitivitySettingsResponse" + } + }, + "default": { + "description": "Error response describing why the operation failed", + "schema": { + "$ref": "../../../common/v1/types.json#/definitions/CloudError" + } + } + }, + "x-ms-examples": { + "Update sensitivity settings": { + "$ref": "./examples/SensitivitySettings/PutSensitivitySettings_example.json" + } + } + }, + "get": { + "tags": [ + "sensitivitySettings" + ], + "description": "Gets data sensitivity settings for sensitive data discovery", + "operationId": "GetSensitivitySettings", + "parameters": [ + { + "$ref": "../../../common/v1/types.json#/parameters/ApiVersion" + } + ], + "responses": { + "200": { + "description": "Success of the sensitivity settings get", + "schema": { + "$ref": "#/definitions/GetSensitivitySettingsResponse" + } + }, + "default": { + "description": "Error response describing why the operation failed", + "schema": { + "$ref": "../../../common/v1/types.json#/definitions/CloudError" + } + } + }, + "x-ms-examples": { + "Get sensitivity settings": { + "$ref": "./examples/SensitivitySettings/GetSensitivitySettings_example.json" + } + } + } + }, + "/providers/Microsoft.Security/sensitivitySettings": { + "get": { + "description": "Gets a list with a single sensitivity settings resource", + "operationId": "SensitivitySettings_List", + "parameters": [ + { + "$ref": "../../../common/v1/types.json#/parameters/ApiVersion" + } + ], + "responses": { + "200": { + "description": "Success of the sensitivity settings list get", + "schema": { + "$ref": "#/definitions/GetSensitivitySettingsListResponse" + } + }, + "default": { + "description": "Error response describing why the operation failed", + "schema": { + "$ref": "../../../common/v1/types.json#/definitions/CloudError" + } + } + }, + "x-ms-examples": { + "Get sensitivity settings list": { + "$ref": "./examples/SensitivitySettings/GetSensitivitySettingsList_example.json" + } + } + } + } + }, + "definitions": { + "SensitiveInfoTypesIds": { + "description": "List of selected sensitive info types' IDs.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" + } + }, + "Label": { + "description": "Microsoft information protection sensitivity label", + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "The display name of the label" + }, + "id": { + "type": "string", + "description": "The ID of the label", + "format": "uuid" + }, + "order": { + "type": "number", + "description": "Labels are ordered by sensitivity level. The higher the order of the label, the more sensitive it is." + } + } + }, + "GetSensitivitySettingsResponse": { + "x-ms-azure-resource": true, + "type": "object", + "description": "Data sensitivity settings for sensitive data discovery", + "properties": { + "id": { + "type": "string", + "description": "The ID of the sensitivity settings", + "readOnly": true + }, + "type": { + "type": "string", + "description": "The type of the sensitivity settings", + "readOnly": true + }, + "name": { + "type": "string", + "description": "The name of the sensitivity settings", + "readOnly": true + }, + "properties": { + "type": "object", + "description": "The sensitivity settings properties", + "properties": { + "sensitiveInfoTypesIds": { + "$ref": "#/definitions/SensitiveInfoTypesIds" + }, + "sensitivityThresholdLabelOrder": { + "type": "number", + "description": "The order of the sensitivity threshold label. Any label at or above this order will be considered sensitive. If set to -1, sensitivity by labels is turned off" + }, + "sensitivityThresholdLabelId": { + "type": "string", + "description": "The id of the sensitivity threshold label. Any label at or above this rank will be considered sensitive.", + "format": "uuid" + }, + "mipInformation": { + "description": "Microsoft information protection built-in and custom information types, labels, and integration status.", + "type": "object", + "properties": { + "mipIntegrationStatus": { + "$ref": "#/definitions/MipIntegrationStatus" + }, + "labels": { + "$ref": "#/definitions/Labels" + }, + "customInfoTypes": { + "description": "List of custom user-defined information types", + "type": "array", + "items": { + "$ref": "#/definitions/InfoType" + } + }, + "builtInInfoTypes": { + "description": "List of pre-configured sensitive information types", + "type": "array", + "items": { + "$ref": "#/definitions/BuiltInInfoType" + } + } + } + } + } + } + } + }, + "GetSensitivitySettingsListResponse": { + "type": "object", + "description": "A list with a single sensitivity settings resource", + "properties": { + "value": { + "type": "array", + "items": { + "$ref": "#/definitions/GetSensitivitySettingsResponse" + } + } + } + }, + "UpdateSensitivitySettingsRequest": { + "description": "Request to update data sensitivity settings for sensitive data discovery", + "type": "object", + "properties": { + "sensitiveInfoTypesIds": { + "$ref": "#/definitions/SensitiveInfoTypesIds" + }, + "sensitivityThresholdLabelOrder": { + "type": "number", + "description": "The order of the sensitivity threshold label. Any label at or above this order will be considered sensitive. If set to -1, sensitivity by labels is turned off" + }, + "sensitivityThresholdLabelId": { + "type": "string", + "description": "The id of the sensitivity threshold label. Any label at or above this rank will be considered sensitive.", + "format": "uuid" + } + }, + "required": [ + "sensitiveInfoTypesIds" + ] + }, + "BuiltInInfoType": { + "description": "Pre-configured sensitive information type", + "type": "object", + "properties": { + "name": { + "description": "Display name of the info type", + "type": "string" + }, + "id": { + "description": "Id of the info type", + "type": "string", + "format": "uuid" + }, + "type": { + "description": "Category of the built-in info type", + "type": "string" + } + } + }, + "InfoType": { + "type": "object", + "description": "Custom user-defined information type", + "properties": { + "name": { + "description": "Display name of the info type", + "type": "string" + }, + "id": { + "description": "Id of the info type", + "type": "string", + "format": "uuid" + }, + "description": { + "description": "Description of the info type", + "type": "string" + } + } + }, + "MipIntegrationStatus": { + "type": "string", + "description": "Microsoft information protection integration status", + "enum": [ + "Ok", + "noConsent", + "noAutoLabelingRules", + "noMipLabels" + ], + "x-ms-enum": { + "name": "MipIntegrationStatus", + "modelAsString": true + } + }, + "Labels": { + "description": "List of Microsoft information protection sensitivity labels", + "type": "array", + "items": { + "$ref": "#/definitions/Label" + } + } + } +} diff --git a/specification/security/resource-manager/readme.md b/specification/security/resource-manager/readme.md index 77e4cd2ad263..a24533198fce 100644 --- a/specification/security/resource-manager/readme.md +++ b/specification/security/resource-manager/readme.md @@ -112,6 +112,7 @@ input-file: - Microsoft.Security/preview/2023-03-01-preview/securityConnectors.json - Microsoft.Security/preview/2023-01-01-preview/securityOperators.json ``` + ### Tag: package-preview-2023-02 These settings apply only when `--tag=package-preview-2023-02` is specified on the command line. @@ -121,7 +122,8 @@ input-file: - Microsoft.Security/preview/2023-02-01-preview/sqlVulnerabilityAssessmentsBaselineRuleOperations.json - Microsoft.Security/preview/2023-02-01-preview/sqlVulnerabilityAssessmentsScanOperations.json - Microsoft.Security/preview/2023-02-01-preview/sqlVulnerabilityAssessmentsScanResultsOperations.json - - Microsoft.Security/preview/2023-02-01-preview/healthReports.json + - Microsoft.Security/preview/2023-02-01-preview/healthReports.json + - Microsoft.Security/preview/2023-02-15-preview/sensitivitySettings.json ``` ### Tag: package-preview-2022-11 @@ -356,6 +358,7 @@ input-file: - Microsoft.Security/stable/2020-01-01/secureScore.json - Microsoft.Security/stable/2020-01-01/SecuritySolutions.json - Microsoft.Security/preview/2020-01-01-preview/connectors.json +- Microsoft.Security/preview/2023-02-15-preview/sensitivitySettings.json - Microsoft.Security/stable/2022-01-01/alerts.json - Microsoft.Security/stable/2022-05-01/settings.json - Microsoft.Security/preview/2021-01-15-preview/ingestionSettings.json