|
| 1 | +{ |
| 2 | + "swagger": "2.0", |
| 3 | + "info": { |
| 4 | + "title": "Security Center", |
| 5 | + "description": "API spec for Microsoft.Security (Azure Security Center) resource provider", |
| 6 | + "version": "2022-12-01-preview" |
| 7 | + }, |
| 8 | + "host": "management.azure.com", |
| 9 | + "schemes": [ |
| 10 | + "https" |
| 11 | + ], |
| 12 | + "consumes": [ |
| 13 | + "application/json" |
| 14 | + ], |
| 15 | + "produces": [ |
| 16 | + "application/json" |
| 17 | + ], |
| 18 | + "security": [ |
| 19 | + { |
| 20 | + "azure_auth": [ |
| 21 | + "user_impersonation" |
| 22 | + ] |
| 23 | + } |
| 24 | + ], |
| 25 | + "securityDefinitions": { |
| 26 | + "azure_auth": { |
| 27 | + "type": "oauth2", |
| 28 | + "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", |
| 29 | + "flow": "implicit", |
| 30 | + "description": "Azure Active Directory OAuth2 Flow", |
| 31 | + "scopes": { |
| 32 | + "user_impersonation": "impersonate your user account" |
| 33 | + } |
| 34 | + } |
| 35 | + }, |
| 36 | + "paths": { |
| 37 | + "/{resourceId}/providers/Microsoft.Security/defenderForStorageSettings/{settingName}": { |
| 38 | + "get": { |
| 39 | + "x-ms-examples": { |
| 40 | + "Gets the Defender for Storage settings for the specified resource.": { |
| 41 | + "$ref": "./examples/DefenderForStorage/GetDefenderForStorageSettings_example.json" |
| 42 | + } |
| 43 | + }, |
| 44 | + "tags": [ |
| 45 | + "DefenderForStorage" |
| 46 | + ], |
| 47 | + "description": "Gets the Defender for Storage settings for the specified storage account.", |
| 48 | + "operationId": "DefenderForStorage_Get", |
| 49 | + "parameters": [ |
| 50 | + { |
| 51 | + "$ref": "../../../common/v1/types.json#/parameters/ApiVersion" |
| 52 | + }, |
| 53 | + { |
| 54 | + "$ref": "../../../common/v1/types.json#/parameters/ResourceId" |
| 55 | + }, |
| 56 | + { |
| 57 | + "$ref": "#/parameters/DefenderForStorageSettingName" |
| 58 | + } |
| 59 | + ], |
| 60 | + "responses": { |
| 61 | + "200": { |
| 62 | + "description": "Successful request to get Defender for Storage settings.", |
| 63 | + "schema": { |
| 64 | + "$ref": "#/definitions/DefenderForStorageSetting" |
| 65 | + } |
| 66 | + }, |
| 67 | + "default": { |
| 68 | + "description": "Error response describing why the operation failed.", |
| 69 | + "schema": { |
| 70 | + "$ref": "../../../common/v1/types.json#/definitions/CloudError" |
| 71 | + } |
| 72 | + } |
| 73 | + } |
| 74 | + }, |
| 75 | + "put": { |
| 76 | + "x-ms-examples": { |
| 77 | + "Creates or updates the Defender for Storage settings on a specified resource.": { |
| 78 | + "$ref": "./examples/DefenderForStorage/PutDefenderForStorageSettings_example.json" |
| 79 | + } |
| 80 | + }, |
| 81 | + "tags": [ |
| 82 | + "DefenderForStorage" |
| 83 | + ], |
| 84 | + "description": "Creates or updates the Defender for Storage settings on a specified storage account.", |
| 85 | + "operationId": "DefenderForStorage_Create", |
| 86 | + "parameters": [ |
| 87 | + { |
| 88 | + "$ref": "../../../common/v1/types.json#/parameters/ApiVersion" |
| 89 | + }, |
| 90 | + { |
| 91 | + "$ref": "../../../common/v1/types.json#/parameters/ResourceId" |
| 92 | + }, |
| 93 | + { |
| 94 | + "$ref": "#/parameters/DefenderForStorageSettingName" |
| 95 | + }, |
| 96 | + { |
| 97 | + "$ref": "#/parameters/DefenderForStorageSetting" |
| 98 | + } |
| 99 | + ], |
| 100 | + "responses": { |
| 101 | + "200": { |
| 102 | + "description": "Successful request to create or update Defender for Storage settings.", |
| 103 | + "schema": { |
| 104 | + "$ref": "#/definitions/DefenderForStorageSetting" |
| 105 | + } |
| 106 | + }, |
| 107 | + "201": { |
| 108 | + "description": "Request to create or update Defender for Storage settings partially succeeded.", |
| 109 | + "schema": { |
| 110 | + "$ref": "#/definitions/DefenderForStorageSetting" |
| 111 | + } |
| 112 | + }, |
| 113 | + "default": { |
| 114 | + "description": "Error response describing why the operation failed.", |
| 115 | + "schema": { |
| 116 | + "$ref": "../../../common/v1/types.json#/definitions/CloudError" |
| 117 | + } |
| 118 | + } |
| 119 | + } |
| 120 | + } |
| 121 | + } |
| 122 | + }, |
| 123 | + "definitions": { |
| 124 | + "DefenderForStorageSetting": { |
| 125 | + "type": "object", |
| 126 | + "allOf": [ |
| 127 | + { |
| 128 | + "$ref": "../../../common/v1/types.json#/definitions/Resource" |
| 129 | + } |
| 130 | + ], |
| 131 | + "properties": { |
| 132 | + "properties": { |
| 133 | + "x-ms-client-flatten": true, |
| 134 | + "$ref": "#/definitions/DefenderForStorageSettingProperties" |
| 135 | + } |
| 136 | + }, |
| 137 | + "description": "The Defender for Storage resource." |
| 138 | + }, |
| 139 | + "DefenderForStorageSettingProperties": { |
| 140 | + "type": "object", |
| 141 | + "properties": { |
| 142 | + "isEnabled": { |
| 143 | + "type": "boolean", |
| 144 | + "description": "Indicates whether Defender for Storage is enabled on this storage account." |
| 145 | + }, |
| 146 | + "malwareScanning": { |
| 147 | + "x-ms-client-flatten": true, |
| 148 | + "$ref": "#/definitions/MalwareScanningProperties" |
| 149 | + }, |
| 150 | + "sensitiveDataDiscovery": { |
| 151 | + "x-ms-client-flatten": true, |
| 152 | + "$ref": "#/definitions/SensitiveDataDiscoveryProperties" |
| 153 | + }, |
| 154 | + "overrideSubscriptionLevelSettings": { |
| 155 | + "type": "boolean", |
| 156 | + "description": "Indicates whether the settings defined for this storage account should override the settings defined for the subscription." |
| 157 | + } |
| 158 | + }, |
| 159 | + "description": "Defender for Storage resource properties." |
| 160 | + }, |
| 161 | + "MalwareScanningProperties": { |
| 162 | + "type": "object", |
| 163 | + "properties": { |
| 164 | + "onUpload": { |
| 165 | + "x-ms-client-flatten": true, |
| 166 | + "$ref": "#/definitions/OnUploadProperties" |
| 167 | + }, |
| 168 | + "operationStatus": { |
| 169 | + "type": "object", |
| 170 | + "$ref": "#/definitions/OperationStatus", |
| 171 | + "readOnly": true, |
| 172 | + "description": "Upon failure or partial success. Additional data describing Malware Scanning enable/disable operation." |
| 173 | + } |
| 174 | + }, |
| 175 | + "description": "Properties of Malware Scanning." |
| 176 | + }, |
| 177 | + "OnUploadProperties": { |
| 178 | + "type": "object", |
| 179 | + "properties": { |
| 180 | + "isEnabled": { |
| 181 | + "type": "boolean", |
| 182 | + "description": "Indicates whether On Upload malware scanning should be enabled." |
| 183 | + }, |
| 184 | + "capGBPerMonth": { |
| 185 | + "type": "integer", |
| 186 | + "format": "int32", |
| 187 | + "description": "Defines the max GB to be scanned per Month. Set to -1 if no capping is needed." |
| 188 | + } |
| 189 | + }, |
| 190 | + "description": "Properties of On Upload malware scanning." |
| 191 | + }, |
| 192 | + "SensitiveDataDiscoveryProperties": { |
| 193 | + "type": "object", |
| 194 | + "properties": { |
| 195 | + "isEnabled": { |
| 196 | + "type": "boolean", |
| 197 | + "description": "Indicates whether Sensitive Data Discovery should be enabled." |
| 198 | + }, |
| 199 | + "operationStatus": { |
| 200 | + "type": "object", |
| 201 | + "$ref": "#/definitions/OperationStatus", |
| 202 | + "readOnly": true, |
| 203 | + "description": "Upon failure or partial success. Additional data describing Sensitive Data Discovery enable/disable operation." |
| 204 | + } |
| 205 | + }, |
| 206 | + "description": "Properties of Sensitive Data Discovery." |
| 207 | + }, |
| 208 | + "OperationStatus": { |
| 209 | + "type": "object", |
| 210 | + "description": "A status describing the success/failure of the enablement/disablement operation.", |
| 211 | + "properties": { |
| 212 | + "code": { |
| 213 | + "type": "string", |
| 214 | + "description": "The operation status code." |
| 215 | + }, |
| 216 | + "message": { |
| 217 | + "type": "string", |
| 218 | + "description": "Additional information regarding the success/failure of the operation." |
| 219 | + } |
| 220 | + } |
| 221 | + } |
| 222 | + }, |
| 223 | + "parameters": { |
| 224 | + "DefenderForStorageSettingName": { |
| 225 | + "name": "settingName", |
| 226 | + "in": "path", |
| 227 | + "required": true, |
| 228 | + "type": "string", |
| 229 | + "pattern": "^[a-z][a-z0-9]*$", |
| 230 | + "enum": [ |
| 231 | + "current" |
| 232 | + ], |
| 233 | + "x-ms-enum": { |
| 234 | + "name": "settingName", |
| 235 | + "modelAsString": true, |
| 236 | + "values": [ |
| 237 | + { |
| 238 | + "value": "current", |
| 239 | + "description": "Name of the Defender for Storage Settings name." |
| 240 | + } |
| 241 | + ] |
| 242 | + }, |
| 243 | + "description": "Defender for Storage setting name.", |
| 244 | + "x-ms-parameter-location": "method" |
| 245 | + }, |
| 246 | + "DefenderForStorageSetting": { |
| 247 | + "name": "defenderForStorageSetting", |
| 248 | + "in": "body", |
| 249 | + "required": true, |
| 250 | + "description": "Defender for Storage Settings", |
| 251 | + "schema": { |
| 252 | + "$ref": "#/definitions/DefenderForStorageSetting" |
| 253 | + }, |
| 254 | + "x-ms-parameter-location": "method" |
| 255 | + } |
| 256 | + } |
| 257 | +} |
0 commit comments