Defender For Storage - Get

Gets the Defender for Storage settings for the specified storage account.

GET https://management.azure.com/{resourceId}/providers/Microsoft.Security/defenderForStorageSettings/current?api-version=2022-12-01-preview

URI Parameters

Name In Required Type Description
resourceId
path True

string

The identifier of the resource.

settingName
path True

settingName

Defender for Storage setting name.

Regex pattern: ^[a-z][a-z0-9]*$

api-version
query True

string

API version for the operation

Responses

Name Type Description
200 OK

DefenderForStorageSetting

Successful request to get Defender for Storage settings.

Other Status Codes

CloudError

Error response describing why the operation failed.

Security

azure_auth

Azure Active Directory OAuth2 Flow

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

Name Description
user_impersonation impersonate your user account

Examples

Gets the Defender for Storage settings for the specified resource.

Sample request

GET https://management.azure.com/subscriptions/20ff7fc3-e762-44dd-bd96-b71116dcdc23/resourceGroups/SampleRG/providers/Microsoft.Storage/storageAccounts/samplestorageaccount/providers/Microsoft.Security/defenderForStorageSettings/current?api-version=2022-12-01-preview

Sample response

{
  "id": "/subscriptions/20ff7fc3-e762-44dd-bd96-b71116dcdc23/resourceGroups/SampleRG/providers/Microsoft.Storage/storageAccounts/samplestorageaccount/providers/Microsoft.Security/defenderForStorageSettings/current",
  "name": "current",
  "type": "Microsoft.Security/defenderForStorageSettings",
  "properties": {
    "isEnabled": true,
    "malwareScanning": {
      "onUpload": {
        "isEnabled": true,
        "capGBPerMonth": -1
      },
      "scanResultsEventGridTopicResourceId": "/subscriptions/20ff7fc3-e762-44dd-bd96-b71116dcdc23/resourceGroups/SampleRG/providers/Microsoft.EventGrid/topics/sampletopic"
    },
    "sensitiveDataDiscovery": {
      "isEnabled": false
    },
    "overrideSubscriptionLevelSettings": true
  }
}

Definitions

Name Description
CloudError

Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.).

CloudErrorBody

The error detail.

DefenderForStorageSetting

The Defender for Storage resource.

DefenderForStorageSettingProperties

Defender for Storage resource properties.

ErrorAdditionalInfo

The resource management error additional info.

MalwareScanningProperties

Properties of Malware Scanning.

OnUploadProperties

Properties of On Upload malware scanning.

OperationStatus

A status describing the success/failure of the enablement/disablement operation.

SensitiveDataDiscoveryProperties

Properties of Sensitive Data Discovery.

settingName

Defender for Storage setting name.

CloudError

Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.).

Name Type Description
error.additionalInfo

ErrorAdditionalInfo[]

The error additional info.

error.code

string

The error code.

error.details

CloudErrorBody[]

The error details.

error.message

string

The error message.

error.target

string

The error target.

CloudErrorBody

The error detail.

Name Type Description
additionalInfo

ErrorAdditionalInfo[]

The error additional info.

code

string

The error code.

details

CloudErrorBody[]

The error details.

message

string

The error message.

target

string

The error target.

DefenderForStorageSetting

The Defender for Storage resource.

Name Type Description
id

string

Resource Id

name

string

Resource name

properties

DefenderForStorageSettingProperties

Defender for Storage resource properties.

type

string

Resource type

DefenderForStorageSettingProperties

Defender for Storage resource properties.

Name Type Description
isEnabled

boolean

Indicates whether Defender for Storage is enabled on this storage account.

malwareScanning

MalwareScanningProperties

Properties of Malware Scanning.

overrideSubscriptionLevelSettings

boolean

Indicates whether the settings defined for this storage account should override the settings defined for the subscription.

sensitiveDataDiscovery

SensitiveDataDiscoveryProperties

Properties of Sensitive Data Discovery.

ErrorAdditionalInfo

The resource management error additional info.

Name Type Description
info

object

The additional info.

type

string

The additional info type.

MalwareScanningProperties

Properties of Malware Scanning.

Name Type Description
onUpload

OnUploadProperties

Properties of On Upload malware scanning.

operationStatus

OperationStatus

Upon failure or partial success. Additional data describing Malware Scanning enable/disable operation.

scanResultsEventGridTopicResourceId

string

Optional. Resource id of an Event Grid Topic to send scan results to.

OnUploadProperties

Properties of On Upload malware scanning.

Name Type Description
capGBPerMonth

integer

Defines the max GB to be scanned per Month. Set to -1 if no capping is needed.

isEnabled

boolean

Indicates whether On Upload malware scanning should be enabled.

OperationStatus

A status describing the success/failure of the enablement/disablement operation.

Name Type Description
code

string

The operation status code.

message

string

Additional information regarding the success/failure of the operation.

SensitiveDataDiscoveryProperties

Properties of Sensitive Data Discovery.

Name Type Description
isEnabled

boolean

Indicates whether Sensitive Data Discovery should be enabled.

operationStatus

OperationStatus

Upon failure or partial success. Additional data describing Sensitive Data Discovery enable/disable operation.

settingName

Defender for Storage setting name.

Name Type Description
current

string

Name of the Defender for Storage Settings name.