lib/aws-sdk-guardduty/client.rb in aws-sdk-guardduty-1.93.0 vs lib/aws-sdk-guardduty/client.rb in aws-sdk-guardduty-1.94.0

- old
+ new

@@ -87,10 +87,15 @@ add_plugin(Aws::Plugins::Protocols::RestJson) add_plugin(Aws::GuardDuty::Plugins::Endpoints) # @overload initialize(options) # @param [Hash] options + # + # @option options [Array<Seahorse::Client::Plugin>] :plugins ([]]) + # A list of plugins to apply to the client. Each plugin is either a + # class name or an instance of a plugin class. + # # @option options [required, Aws::CredentialProvider] :credentials # Your AWS credentials. This can be an instance of any one of the # following classes: # # * `Aws::Credentials` - Used for configuring static, non-refreshing @@ -207,11 +212,10 @@ # # 'http://example.com' # 'https://example.com' # 'http://example.com:123' # - # # @option options [Integer] :endpoint_cache_max_entries (1000) # Used for the maximum size limit of the LRU cache storing endpoints data # for endpoint discovery enabled operations. Defaults to 1000. # # @option options [Integer] :endpoint_cache_max_threads (10) @@ -296,11 +300,10 @@ # * `adaptive` - An experimental retry mode that includes all the # functionality of `standard` mode along with automatic client side # throttling. This is a provisional mode that may change behavior # in the future. # - # # @option options [String] :sdk_ua_app_id # A unique and opaque application ID that is appended to the # User-Agent header as app/sdk_ua_app_id. It should have a # maximum length of 50. This variable is sourced from environment # variable AWS_SDK_UA_APP_ID or the shared config profile attribute sdk_ua_app_id. @@ -1004,10 +1007,81 @@ def create_ip_set(params = {}, options = {}) req = build_request(:create_ip_set, params) req.send_request(options) end + # Creates a new Malware Protection plan for the protected resource. + # + # When you create a Malware Protection plan, the Amazon Web Services + # service terms for GuardDuty Malware Protection apply. For more + # information, see [Amazon Web Services service terms for GuardDuty + # Malware Protection][1]. + # + # + # + # [1]: http://aws.amazon.com/service-terms/#87._Amazon_GuardDuty + # + # @option params [String] :client_token + # The idempotency token for the create request. + # + # **A suitable default value is auto-generated.** You should normally + # not need to pass this option.** + # + # @option params [required, String] :role + # IAM role with permissions required to scan and add tags to the + # associated protected resource. + # + # @option params [required, Types::CreateProtectedResource] :protected_resource + # Information about the protected resource that is associated with the + # created Malware Protection plan. Presently, `S3Bucket` is the only + # supported protected resource. + # + # @option params [Types::MalwareProtectionPlanActions] :actions + # Information about whether the tags will be added to the S3 object + # after scanning. + # + # @option params [Hash<String,String>] :tags + # Tags added to the Malware Protection plan resource. + # + # @return [Types::CreateMalwareProtectionPlanResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::CreateMalwareProtectionPlanResponse#malware_protection_plan_id #malware_protection_plan_id} => String + # + # @example Request syntax with placeholder values + # + # resp = client.create_malware_protection_plan({ + # client_token: "ClientToken", + # role: "String", # required + # protected_resource: { # required + # s3_bucket: { + # bucket_name: "String", + # object_prefixes: ["String"], + # }, + # }, + # actions: { + # tagging: { + # status: "ENABLED", # accepts ENABLED, DISABLED + # }, + # }, + # tags: { + # "TagKey" => "TagValue", + # }, + # }) + # + # @example Response structure + # + # resp.malware_protection_plan_id #=> String + # + # @see http://docs.aws.amazon.com/goto/WebAPI/guardduty-2017-11-28/CreateMalwareProtectionPlan AWS API Documentation + # + # @overload create_malware_protection_plan(params = {}) + # @param [Hash] params ({}) + def create_malware_protection_plan(params = {}, options = {}) + req = build_request(:create_malware_protection_plan, params) + req.send_request(options) + end + # Creates member accounts of the current Amazon Web Services account by # specifying a list of Amazon Web Services account IDs. This step is a # prerequisite for managing the associated member accounts either by # invitation or through an organization. # @@ -1363,10 +1437,34 @@ def delete_invitations(params = {}, options = {}) req = build_request(:delete_invitations, params) req.send_request(options) end + # Deletes the Malware Protection plan ID associated with the Malware + # Protection plan resource. Use this API only when you no longer want to + # protect the resource associated with this Malware Protection plan ID. + # + # @option params [required, String] :malware_protection_plan_id + # A unique identifier associated with Malware Protection plan resource. + # + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # + # @example Request syntax with placeholder values + # + # resp = client.delete_malware_protection_plan({ + # malware_protection_plan_id: "String", # required + # }) + # + # @see http://docs.aws.amazon.com/goto/WebAPI/guardduty-2017-11-28/DeleteMalwareProtectionPlan AWS API Documentation + # + # @overload delete_malware_protection_plan(params = {}) + # @param [Hash] params ({}) + def delete_malware_protection_plan(params = {}, options = {}) + req = build_request(:delete_malware_protection_plan, params) + req.send_request(options) + end + # Deletes GuardDuty member accounts (to the current GuardDuty # administrator account) specified by the account IDs. # # With `autoEnableOrganizationMembers` configuration for your # organization set to `ALL`, you'll receive an error if you attempt to @@ -2162,10 +2260,16 @@ # resp.findings[0].resource.s3_bucket_details[0].public_access.permission_configuration.account_level_permissions.block_public_access.ignore_public_acls #=> Boolean # resp.findings[0].resource.s3_bucket_details[0].public_access.permission_configuration.account_level_permissions.block_public_access.restrict_public_buckets #=> Boolean # resp.findings[0].resource.s3_bucket_details[0].public_access.permission_configuration.account_level_permissions.block_public_access.block_public_acls #=> Boolean # resp.findings[0].resource.s3_bucket_details[0].public_access.permission_configuration.account_level_permissions.block_public_access.block_public_policy #=> Boolean # resp.findings[0].resource.s3_bucket_details[0].public_access.effective_permission #=> String + # resp.findings[0].resource.s3_bucket_details[0].s3_object_details #=> Array + # resp.findings[0].resource.s3_bucket_details[0].s3_object_details[0].object_arn #=> String + # resp.findings[0].resource.s3_bucket_details[0].s3_object_details[0].key #=> String + # resp.findings[0].resource.s3_bucket_details[0].s3_object_details[0].etag #=> String + # resp.findings[0].resource.s3_bucket_details[0].s3_object_details[0].hash #=> String + # resp.findings[0].resource.s3_bucket_details[0].s3_object_details[0].version_id #=> String # resp.findings[0].resource.instance_details.availability_zone #=> String # resp.findings[0].resource.instance_details.iam_instance_profile.arn #=> String # resp.findings[0].resource.instance_details.iam_instance_profile.id #=> String # resp.findings[0].resource.instance_details.image_description #=> String # resp.findings[0].resource.instance_details.image_id #=> String @@ -2583,10 +2687,16 @@ # resp.findings[0].service.detection.anomaly.unusual.behavior["String"] #=> Hash # resp.findings[0].service.detection.anomaly.unusual.behavior["String"]["String"].profile_type #=> String, one of "FREQUENCY" # resp.findings[0].service.detection.anomaly.unusual.behavior["String"]["String"].profile_subtype #=> String, one of "FREQUENT", "INFREQUENT", "UNSEEN", "RARE" # resp.findings[0].service.detection.anomaly.unusual.behavior["String"]["String"].observations.text #=> Array # resp.findings[0].service.detection.anomaly.unusual.behavior["String"]["String"].observations.text[0] #=> String + # resp.findings[0].service.malware_scan_details.threats #=> Array + # resp.findings[0].service.malware_scan_details.threats[0].name #=> String + # resp.findings[0].service.malware_scan_details.threats[0].source #=> String + # resp.findings[0].service.malware_scan_details.threats[0].item_paths #=> Array + # resp.findings[0].service.malware_scan_details.threats[0].item_paths[0].nested_item_path #=> String + # resp.findings[0].service.malware_scan_details.threats[0].item_paths[0].hash #=> String # resp.findings[0].severity #=> Float # resp.findings[0].title #=> String # resp.findings[0].type #=> String # resp.findings[0].updated_at #=> String # @@ -2723,10 +2833,58 @@ def get_invitations_count(params = {}, options = {}) req = build_request(:get_invitations_count, params) req.send_request(options) end + # Retrieves the Malware Protection plan details associated with a + # Malware Protection plan ID. + # + # @option params [required, String] :malware_protection_plan_id + # A unique identifier associated with Malware Protection plan resource. + # + # @return [Types::GetMalwareProtectionPlanResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::GetMalwareProtectionPlanResponse#arn #arn} => String + # * {Types::GetMalwareProtectionPlanResponse#role #role} => String + # * {Types::GetMalwareProtectionPlanResponse#protected_resource #protected_resource} => Types::CreateProtectedResource + # * {Types::GetMalwareProtectionPlanResponse#actions #actions} => Types::MalwareProtectionPlanActions + # * {Types::GetMalwareProtectionPlanResponse#created_at #created_at} => Time + # * {Types::GetMalwareProtectionPlanResponse#status #status} => String + # * {Types::GetMalwareProtectionPlanResponse#status_reasons #status_reasons} => Array&lt;Types::MalwareProtectionPlanStatusReason&gt; + # * {Types::GetMalwareProtectionPlanResponse#tags #tags} => Hash&lt;String,String&gt; + # + # @example Request syntax with placeholder values + # + # resp = client.get_malware_protection_plan({ + # malware_protection_plan_id: "String", # required + # }) + # + # @example Response structure + # + # resp.arn #=> String + # resp.role #=> String + # resp.protected_resource.s3_bucket.bucket_name #=> String + # resp.protected_resource.s3_bucket.object_prefixes #=> Array + # resp.protected_resource.s3_bucket.object_prefixes[0] #=> String + # resp.actions.tagging.status #=> String, one of "ENABLED", "DISABLED" + # resp.created_at #=> Time + # resp.status #=> String, one of "ACTIVE", "WARNING", "ERROR" + # resp.status_reasons #=> Array + # resp.status_reasons[0].code #=> String + # resp.status_reasons[0].message #=> String + # resp.tags #=> Hash + # resp.tags["TagKey"] #=> String + # + # @see http://docs.aws.amazon.com/goto/WebAPI/guardduty-2017-11-28/GetMalwareProtectionPlan AWS API Documentation + # + # @overload get_malware_protection_plan(params = {}) + # @param [Hash] params ({}) + def get_malware_protection_plan(params = {}, options = {}) + req = build_request(:get_malware_protection_plan, params) + req.send_request(options) + end + # Returns the details of 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 @@ -3696,10 +3854,46 @@ def list_invitations(params = {}, options = {}) req = build_request(:list_invitations, params) req.send_request(options) end + # Lists the Malware Protection plan IDs associated with the protected + # resources in your Amazon Web Services account. + # + # @option params [String] :next_token + # You can use this parameter when paginating results. Set the value of + # this parameter to null on your first call to the list action. For + # subsequent calls to the action, fill nextToken in the request with the + # value of `NextToken` from the previous response to continue listing + # data. + # + # @return [Types::ListMalwareProtectionPlansResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: + # + # * {Types::ListMalwareProtectionPlansResponse#malware_protection_plans #malware_protection_plans} => Array&lt;Types::MalwareProtectionPlanSummary&gt; + # * {Types::ListMalwareProtectionPlansResponse#next_token #next_token} => String + # + # @example Request syntax with placeholder values + # + # resp = client.list_malware_protection_plans({ + # next_token: "String", + # }) + # + # @example Response structure + # + # resp.malware_protection_plans #=> Array + # resp.malware_protection_plans[0].malware_protection_plan_id #=> String + # resp.next_token #=> String + # + # @see http://docs.aws.amazon.com/goto/WebAPI/guardduty-2017-11-28/ListMalwareProtectionPlans AWS API Documentation + # + # @overload list_malware_protection_plans(params = {}) + # @param [Hash] params ({}) + def list_malware_protection_plans(params = {}, options = {}) + req = build_request(:list_malware_protection_plans, params) + req.send_request(options) + end + # Lists details about all member accounts for the current GuardDuty # administrator account. # # @option params [required, String] :detector_id # The unique ID of the detector the member is associated with. @@ -4379,10 +4573,56 @@ def update_ip_set(params = {}, options = {}) req = build_request(:update_ip_set, params) req.send_request(options) end + # Updates an existing Malware Protection plan resource. + # + # @option params [required, String] :malware_protection_plan_id + # A unique identifier associated with the Malware Protection plan. + # + # @option params [String] :role + # IAM role with permissions required to scan and add tags to the + # associated protected resource. + # + # @option params [Types::MalwareProtectionPlanActions] :actions + # Information about whether the tags will be added to the S3 object + # after scanning. + # + # @option params [Types::UpdateProtectedResource] :protected_resource + # Information about the protected resource that is associated with the + # created Malware Protection plan. Presently, `S3Bucket` is the only + # supported protected resource. + # + # @return [Struct] Returns an empty {Seahorse::Client::Response response}. + # + # @example Request syntax with placeholder values + # + # resp = client.update_malware_protection_plan({ + # malware_protection_plan_id: "String", # required + # role: "String", + # actions: { + # tagging: { + # status: "ENABLED", # accepts ENABLED, DISABLED + # }, + # }, + # protected_resource: { + # s3_bucket: { + # object_prefixes: ["String"], + # }, + # }, + # }) + # + # @see http://docs.aws.amazon.com/goto/WebAPI/guardduty-2017-11-28/UpdateMalwareProtectionPlan AWS API Documentation + # + # @overload update_malware_protection_plan(params = {}) + # @param [Hash] params ({}) + def update_malware_protection_plan(params = {}, options = {}) + req = build_request(:update_malware_protection_plan, params) + req.send_request(options) + end + # 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 @@ -4732,10 +4972,10 @@ operation: config.api.operation(operation_name), client: self, params: params, config: config) context[:gem_name] = 'aws-sdk-guardduty' - context[:gem_version] = '1.93.0' + context[:gem_version] = '1.94.0' Seahorse::Client::Request.new(handlers, context) end # @api private # @deprecated