GuardDuty / Client / update_malware_scan_settings

update_malware_scan_settings#

GuardDuty.Client.update_malware_scan_settings(**kwargs)#

Updates the malware scan settings.

There might be regional differences because some data sources might not be available in all the Amazon Web Services Regions where GuardDuty is presently supported. For more information, see Regions and endpoints.

See also: AWS API Documentation

Request Syntax

response = client.update_malware_scan_settings(
    DetectorId='string',
    ScanResourceCriteria={
        'Include': {
            'string': {
                'MapEquals': [
                    {
                        'Key': 'string',
                        'Value': 'string'
                    },
                ]
            }
        },
        'Exclude': {
            'string': {
                'MapEquals': [
                    {
                        'Key': 'string',
                        'Value': 'string'
                    },
                ]
            }
        }
    },
    EbsSnapshotPreservation='NO_RETENTION'|'RETENTION_WITH_FINDING'
)
Parameters:
  • DetectorId (string) –

    [REQUIRED]

    The unique ID of the detector that specifies the GuardDuty service where you want to update scan settings.

    To find the detectorId in the current Region, see the Settings page in the GuardDuty console, or run the ListDetectors API.

  • ScanResourceCriteria (dict) –

    Represents the criteria to be used in the filter for selecting resources to scan.

    • Include (dict) –

      Represents condition that when matched will allow a malware scan for a certain resource.

      • (string) –

        An enum value representing possible resource properties to match with given scan condition.

        • (dict) –

          Contains information about the condition.

          • MapEquals (list) – [REQUIRED]

            Represents an mapEqual condition to be applied to a single field when triggering for malware scan.

            • (dict) –

              Represents the key:value pair to be matched against given resource property.

              • Key (string) – [REQUIRED]

                Represents the key in the map condition.

              • Value (string) –

                Represents optional value in the map condition. If not specified, only the key will be matched.

    • Exclude (dict) –

      Represents condition that when matched will prevent a malware scan for a certain resource.

      • (string) –

        An enum value representing possible resource properties to match with given scan condition.

        • (dict) –

          Contains information about the condition.

          • MapEquals (list) – [REQUIRED]

            Represents an mapEqual condition to be applied to a single field when triggering for malware scan.

            • (dict) –

              Represents the key:value pair to be matched against given resource property.

              • Key (string) – [REQUIRED]

                Represents the key in the map condition.

              • Value (string) –

                Represents optional value in the map condition. If not specified, only the key will be matched.

  • EbsSnapshotPreservation (string) – An enum value representing possible snapshot preservation settings.

Return type:

dict

Returns:

Response Syntax

{}

Response Structure

  • (dict) –

Exceptions

  • GuardDuty.Client.exceptions.BadRequestException

  • GuardDuty.Client.exceptions.InternalServerErrorException