Skip to content

Commit 278558c

Browse files
author
Yuval Reshef
committed
fixes for configure guide for defender for storage
1 parent 45d3693 commit 278558c

File tree

1 file changed

+22
-27
lines changed

1 file changed

+22
-27
lines changed

articles/storage/common/azure-defender-storage-configure.md

Lines changed: 22 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ There are several ways to enable Defender for Storage on subscriptions:
8888
- [Azure portal](#azure-portal)
8989
- [Azure built-in policy](#enable-and-configure-at-scale-with-an-azure-built-in-policy)
9090
- IaC templates, including [Bicep](#bicep-template) and [ARM](#arm-template)
91-
- [REST API](#rest-api)
91+
- [REST API](#enable-and-configure-with-rest-api)
9292

9393
> [!TIP]
9494
> You can [override or set custom configuration settings](#override-defender-for-storage-subscription-level-settings) for specific storage accounts within protected subscriptions.
@@ -203,7 +203,7 @@ If you want to turn off the **On-upload malware scanning** or **Sensitive data t
203203

204204
To disable the entire Defender plan, set the `pricingTier` property value to `Free` and remove the `subPlan` and `extensions` properties.
205205

206-
Learn more about the [ARM template AzAPI reference](/azure/templates/microsoft.security/pricings?pivots=deployment-language-arm-template).
206+
Learn more in the [ARM template reference](/azure/templates/microsoft.security/pricings?pivots=deployment-language-arm-template).
207207

208208
### Enable and configure with REST API
209209

@@ -251,7 +251,7 @@ You can enable and configure Microsoft Defender for Storage on specific storage
251251

252252
- [Azure portal](#azure-portal-1)
253253
- IaC templates, including [Bicep](#bicep-template-1) and [ARM](#arm-template-1)
254-
- [REST API](#rest-api-1)
254+
- [REST API](#rest-api)
255255

256256
The steps below include instructions on how to set up logging and an Event Grid for the Malware Scanning.
257257

@@ -273,7 +273,7 @@ Microsoft Defender for Storage is now enabled on this storage account.
273273
> To configure **On-upload malware scanning** settings, such as monthly cap, select **Settings** after Defender for Storage was enabled.
274274
> :::image type="content" source="../../defender-for-cloud/media/azure-defender-storage-configure/malware-scan-capping.png" alt-text="Screenshot showing where to configure a monthly cap for Malware Scanning.":::
275275
276-
If you want to disable Defender for Storage on the storage account or disable one of the features (On-upload malware scanning or Sensitive data threat detection), select**Settings**, edit the settings, and select **Save**.
276+
If you want to disable Defender for Storage on the storage account or disable one of the features (On-upload malware scanning or Sensitive data threat detection), select **Settings**, edit the settings, and select **Save**.
277277

278278
### Enable and configure with IaC templates
279279

@@ -303,14 +303,11 @@ To enable and configure Microsoft Defender for Storage at the storage account le
303303
}
304304
```
305305

306-
To modify the monthly threshold for malware scanning in your storage accounts, simply adjust the `CapGBPerMonthPerStorageAccount` parameter to your preferred value. This parameter sets a cap on the maximum data that can be scanned for malware each month, per storage account. If you want to permit unlimited scanning, assign the value `-1`. The default limit is set at 5,000 GB.
306+
To modify the monthly threshold for malware scanning in your storage accounts, simply adjust the `capGBPerMonth` parameter to your preferred value. This parameter sets a cap on the maximum data that can be scanned for malware each month, per storage account. If you want to permit unlimited scanning, assign the value `-1`. The default limit is set at 5,000 GB.
307307

308-
If you want to turn off the **On-upload malware scanning** or **Sensitive data threat detection** features, you can change the `isEnabled` value to `false` under Sensitive data discovery.
309-
310-
To disable the entire Defender plan, set the `pricingTier` property value to `Free` and remove the `subPlan` and `extensions` properties.
311-
312-
Learn more about the [ARM template AzAPI reference](/azure/templates/microsoft.security/pricings?pivots=deployment-language-arm-template).
308+
If you want to turn off the **On-upload malware scanning** or **Sensitive data threat detection** features, you can change the `isEnabled` value to `false` under the `malwareScanning` or `sensitiveDataDiscovery` properties sections.
313309

310+
To disable the entire Defender plan for the storage account, set the `isEnabled` property value to `false` and remove the `malwareScanning` and `sensitiveDataDiscovery` sections from the properties.
314311
#### Bicep template
315312

316313
To enable and configure Microsoft Defender for Storage at the storage account level using [Bicep](../../azure-resource-manager/bicep/overview.md), add the following to your Bicep template:
@@ -337,11 +334,11 @@ resource defenderForStorageSettings 'Microsoft.Security/DefenderForStorageSettin
337334
}
338335
```
339336

340-
To modify the monthly threshold for malware scanning in your storage accounts, simply adjust the `CapGBPerMonthPerStorageAccount` parameter to your preferred value. This parameter sets a cap on the maximum data that can be scanned for malware each month, per storage account. If you want to permit unlimited scanning, assign the value `-1`. The default limit is set at 5,000 GB.
337+
To modify the monthly threshold for malware scanning in your storage accounts, simply adjust the `capGBPerMonth` parameter to your preferred value. This parameter sets a cap on the maximum data that can be scanned for malware each month, per storage account. If you want to permit unlimited scanning, assign the value `-1`. The default limit is set at 5,000 GB.
341338

342-
If you want to turn off the **On-upload malware scanning** or **Sensitive data threat detection** features, you can change the `isEnabled` value to `false` under Sensitive data discovery.
339+
If you want to turn off the **On-upload malware scanning** or **Sensitive data threat detection** features, you can change the `isEnabled` value to `false` under the `malwareScanning` or `sensitiveDataDiscovery` properties sections.
343340

344-
To disable the entire Defender plan, set the `pricingTier` property value to `Free` and remove the `subPlan` and `extensions` properties.
341+
To disable the entire Defender plan for the storage account, set the `isEnabled` property value to `false` and remove the `malwareScanning` and `sensitiveDataDiscovery` sections from the properties.
345342

346343
Learn more about the [Bicep template AzAPI reference](/azure/templates/microsoft.security/pricings?pivots=deployment-language-bicep&source=docs).
347344

@@ -350,7 +347,8 @@ Learn more about the [Bicep template AzAPI reference](/azure/templates/microsoft
350347
To enable and configure Microsoft Defender for Storage at the storage account level using REST API, create a PUT request with this endpoint. Replace the `subscriptionId` , `resourceGroupName`, and `accountName` in the endpoint URL with your own Azure subscription ID, resource group and storage account names accordingly.
351348

352349
```http
353-
PUT https://management.azure.com/subscriptions/{subscriptionId}/providers/Microsoft.Security/pricings/StorageAccounts?api-version=2023-01-01
350+
PUT
351+
https://management.azure.com/subscriptions/{subscriptionId}/providers/Microsoft.Storage/storageAccounts/{accountName}/providers/Microsoft.Security/defenderForStorageSettings/current?api-version=2022-12-01-preview
354352
```
355353

356354
And add the following request body:
@@ -368,16 +366,16 @@ And add the following request body:
368366
"sensitiveDataDiscovery": {
369367
"isEnabled": true
370368
},
371-
"overrideSubscriptionLevelSettings": false
369+
"overrideSubscriptionLevelSettings": true
372370
}
373371
}
374372
```
375373

376-
To modify the monthly threshold for malware scanning in your storage accounts, simply adjust the `CapGBPerMonthPerStorageAccount` parameter to your preferred value. This parameter sets a cap on the maximum data that can be scanned for malware each month, per storage account. If you want to permit unlimited scanning, assign the value `-1`. The default limit is set at 5,000 GB.
374+
To modify the monthly threshold for malware scanning in your storage accounts, simply adjust the `capGBPerMonth` parameter to your preferred value. This parameter sets a cap on the maximum data that can be scanned for malware each month, per storage account. If you want to permit unlimited scanning, assign the value `-1`. The default limit is set at 5,000 GB.
377375

378-
If you want to turn off the **On-upload malware scanning** or **Sensitive data threat detection** features, you can change the `isEnabled` value to `false` under Sensitive data discovery.
376+
If you want to turn off the **On-upload malware scanning** or **Sensitive data threat detection** features, you can change the `isEnabled` value to `false` under the `malwareScanning` or `sensitiveDataDiscovery` properties sections.
379377

380-
To disable the entire Defender plan, set the `pricingTier` property value to `Free` and remove the `subPlan` and `extensions` properties.
378+
To disable the entire Defender plan for the storage account, set the `isEnabled` property value to `false` and remove the `malwareScanning` and `sensitiveDataDiscovery` sections from the properties.
381379

382380
Learn more about the [updating Defender plans with the REST API](/rest/api/defenderforcloud/pricings/update) in HTTP, Java, Go and JavaScript.
383381

@@ -399,20 +397,18 @@ Request URL:
399397

400398
```http
401399
PUT
402-
https://management.azure.com/subscriptions/<subscription-id>/resourceGroups/<resourcegroup-name>/providers/Microsoft.Storage/storageAccounts/<storage-account-name>
403-
/providers/Microsoft.Security/antiMalwareSettings/current/providers/Microsoft.Insights/
404-
diagnosticSettings/service?api-version=2021-05-01-preview
400+
https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Storage/storageAccounts/{accountName}/providers/Microsoft.Security/DefenderForStorageSettings/current/providers/Microsoft.Insights/diagnosticSettings/service?api-version=2021-05-01-preview
405401
```
406402

407403
Request Body:
408404

409405
```json
410406
{
411407
"properties": {
412-
"workspaceId": "/subscriptions/704601a1-0ac4-4d5d-aecd-322835fbde2f/resourcegroups/demorg/providers/microsoft.operationalinsights/workspaces/malwarescanningscanresultworkspace",
408+
"workspaceId": "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroup}/providers/microsoft.operationalinsights/workspaces/{workspaceName}",
413409
"logs": [
414410
{
415-
"categoryGroup": "allLogs",
411+
"category": "ScanResults",
416412
"enabled": true,
417413
"retentionPolicy": {
418414
"enabled": true,
@@ -443,8 +439,7 @@ Request URL:
443439

444440
```http
445441
PUT
446-
https://management.azure.com/subscriptions/<subscription-id>/resourceGroups/<resourcegroup-name>/providers/Microsoft.Storage/storageAccounts/<storage-account-name>
447-
/providers/Microsoft.Security/DefenderForStorageSettings/current?api-version=2022-12-01-preview
442+
https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Storage/storageAccounts/{accountName}/providers/Microsoft.Security/DefenderForStorageSettings/current?api-version=2022-12-01-preview
448443
```
449444

450445
Request Body:
@@ -458,7 +453,7 @@ Request Body:
458453
"isEnabled": true,
459454
"capGBPerMonth": 5000
460455
},
461-
"scanResultsEventGridTopicResourceId": "/subscriptions/704601a1-0ac4-4d5d-aecd-322835fbde2f/resourceGroups/DemoRG/providers/Microsoft.EventGrid/topics/ScanResultsEGCustomTopic"
456+
"scanResultsEventGridTopicResourceId": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.EventGrid/topics/{EventGridTopicName}"
462457
},
463458
"sensitiveDataDiscovery": {
464459
"isEnabled": true
@@ -529,7 +524,7 @@ To override Defender for Storage subscription-level settings to configure settin
529524

530525
```http
531526
PUT
532-
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/providers/Microsoft.Security/DefenderForStorageSettings/current?api-version=2022-12-01-preview
527+
https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/providers/Microsoft.Security/DefenderForStorageSettings/current?api-version=2022-12-01-preview
533528
```
534529
535530
Request Body:

0 commit comments

Comments
 (0)