Malware Protection Plan
Provides a resource to manage a GuardDuty malware protection plan.
Example Usage
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.guardduty.MalwareProtectionPlan;
import com.pulumi.aws.guardduty.MalwareProtectionPlanArgs;
import com.pulumi.aws.guardduty.inputs.MalwareProtectionPlanProtectedResourceArgs;
import com.pulumi.aws.guardduty.inputs.MalwareProtectionPlanProtectedResourceS3BucketArgs;
import com.pulumi.aws.guardduty.inputs.MalwareProtectionPlanActionArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new MalwareProtectionPlan("example", MalwareProtectionPlanArgs.builder()
.role(exampleAwsIamRole.arn())
.protectedResource(MalwareProtectionPlanProtectedResourceArgs.builder()
.s3Bucket(MalwareProtectionPlanProtectedResourceS3BucketArgs.builder()
.bucketName(exampleAwsS3Bucket.id())
.objectPrefixes(
"example1",
"example2")
.build())
.build())
.actions(MalwareProtectionPlanActionArgs.builder()
.tagging(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))
.build())
.tags(Map.of("Name", "example"))
.build());
}
}
Content copied to clipboard
resources:
example:
type: aws:guardduty:MalwareProtectionPlan
properties:
role: ${exampleAwsIamRole.arn}
protectedResource:
s3Bucket:
bucketName: ${exampleAwsS3Bucket.id}
objectPrefixes:
- example1
- example2
actions:
- tagging:
- status: ENABLED
tags:
Name: example
Content copied to clipboard
Import
Using pulumi import
, import GuardDuty malware protection plans using their IDs. For example:
$ pulumi import aws:guardduty/malwareProtectionPlan:MalwareProtectionPlan example 1234567890abcdef0123
Content copied to clipboard
Properties
Link copied to clipboard
Information about whether the tags will be added to the S3 object after scanning. See actions
below.
Link copied to clipboard
Information about the protected resource that is associated with the created Malware Protection plan. Presently, S3Bucket is the only supported protected resource. See protected_resource
below.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard