java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
All Implemented Interfaces:
IInspectable, IEnvironmentAware, IPentestRef, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.127.0 (build 2117ad5)", date="2026-04-14T18:32:04.505Z") @Stability(Stable) public class CfnPentest extends CfnResource implements IInspectable, IPentestRef
Resource Type definition for AWS::SecurityAgent::Pentest.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.securityagent.*;
 CfnPentest cfnPentest = CfnPentest.Builder.create(this, "MyCfnPentest")
         .agentSpaceId("agentSpaceId")
         .assets(AssetsProperty.builder()
                 .actors(List.of(ActorProperty.builder()
                         .authentication(AuthenticationProperty.builder()
                                 .providerType("providerType")
                                 .value("value")
                                 .build())
                         .description("description")
                         .identifier("identifier")
                         .uris(List.of("uris"))
                         .build()))
                 .documents(List.of(DocumentInfoProperty.builder()
                         .artifactId("artifactId")
                         .s3Location("s3Location")
                         .build()))
                 .endpoints(List.of(EndpointProperty.builder()
                         .uri("uri")
                         .build()))
                 .integratedRepositories(List.of(IntegratedRepositoryProperty.builder()
                         .integrationId("integrationId")
                         .providerResourceId("providerResourceId")
                         .build()))
                 .sourceCode(List.of(SourceCodeRepositoryProperty.builder()
                         .s3Location("s3Location")
                         .build()))
                 .build())
         .serviceRole("serviceRole")
         // the properties below are optional
         .codeRemediationStrategy("codeRemediationStrategy")
         .excludeRiskTypes(List.of("excludeRiskTypes"))
         .logConfig(CloudWatchLogProperty.builder()
                 .logGroup("logGroup")
                 .logStream("logStream")
                 .build())
         .networkTrafficConfig(NetworkTrafficConfigProperty.builder()
                 .customHeaders(List.of(CustomHeaderProperty.builder()
                         .name("name")
                         .value("value")
                         .build()))
                 .rules(List.of(NetworkTrafficRuleProperty.builder()
                         .effect("effect")
                         .networkTrafficRuleType("networkTrafficRuleType")
                         .pattern("pattern")
                         .build()))
                 .build())
         .title("title")
         .vpcConfig(VpcConfigProperty.builder()
                 .securityGroupArns(List.of("securityGroupArns"))
                 .subnetArns(List.of("subnetArns"))
                 .vpcArn("vpcArn")
                 .build())
         .build();
 

See Also:
  • Field Details

    • CFN_RESOURCE_TYPE_NAME

      @Stability(Stable) public static final String CFN_RESOURCE_TYPE_NAME
      The CloudFormation resource type name for this resource class.
  • Constructor Details

    • CfnPentest

      protected CfnPentest(software.amazon.jsii.JsiiObjectRef objRef)
    • CfnPentest

      protected CfnPentest(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • CfnPentest

      @Stability(Stable) public CfnPentest(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnPentestProps props)
      Create a new AWS::SecurityAgent::Pentest.

      Parameters:
      scope - Scope in which this resource is defined. This parameter is required.
      id - Construct identifier for this resource (unique in its scope). This parameter is required.
      props - Resource properties. This parameter is required.
  • Method Details

    • isCfnPentest

      @Stability(Stable) @NotNull public static Boolean isCfnPentest(@NotNull Object x)
      Checks whether the given object is a CfnPentest.

      Parameters:
      x - This parameter is required.
    • inspect

      @Stability(Stable) public void inspect(@NotNull TreeInspector inspector)
      Examines the CloudFormation resource and discloses attributes.

      Specified by:
      inspect in interface IInspectable
      Parameters:
      inspector - tree inspector to collect and process attributes. This parameter is required.
    • renderProperties

      @Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
      Overrides:
      renderProperties in class CfnResource
      Parameters:
      props - This parameter is required.
    • getAttrCreatedAt

      @Stability(Stable) @NotNull public String getAttrCreatedAt()
    • getAttrPentestId

      @Stability(Stable) @NotNull public String getAttrPentestId()
    • getAttrUpdatedAt

      @Stability(Stable) @NotNull public String getAttrUpdatedAt()
    • getCfnProperties

      @Stability(Stable) @NotNull protected Map<String,Object> getCfnProperties()
      Overrides:
      getCfnProperties in class CfnResource
    • getPentestRef

      @Stability(Stable) @NotNull public PentestReference getPentestRef()
      A reference to a Pentest resource.
      Specified by:
      getPentestRef in interface IPentestRef
    • getAgentSpaceId

      @Stability(Stable) @NotNull public String getAgentSpaceId()
    • setAgentSpaceId

      @Stability(Stable) public void setAgentSpaceId(@NotNull String value)
    • getAssets

      @Stability(Stable) @NotNull public Object getAssets()
      Returns union: either IResolvable or CfnPentest.AssetsProperty
    • setAssets

      @Stability(Stable) public void setAssets(@NotNull IResolvable value)
    • setAssets

      @Stability(Stable) public void setAssets(@NotNull CfnPentest.AssetsProperty value)
    • getServiceRole

      @Stability(Stable) @NotNull public String getServiceRole()
    • setServiceRole

      @Stability(Stable) public void setServiceRole(@NotNull String value)
    • getCodeRemediationStrategy

      @Stability(Stable) @Nullable public String getCodeRemediationStrategy()
    • setCodeRemediationStrategy

      @Stability(Stable) public void setCodeRemediationStrategy(@Nullable String value)
    • getExcludeRiskTypes

      @Stability(Stable) @Nullable public List<String> getExcludeRiskTypes()
    • setExcludeRiskTypes

      @Stability(Stable) public void setExcludeRiskTypes(@Nullable List<String> value)
    • getLogConfig

      @Stability(Stable) @Nullable public Object getLogConfig()
    • setLogConfig

      @Stability(Stable) public void setLogConfig(@Nullable IResolvable value)
    • setLogConfig

      @Stability(Stable) public void setLogConfig(@Nullable CfnPentest.CloudWatchLogProperty value)
    • getNetworkTrafficConfig

      @Stability(Stable) @Nullable public Object getNetworkTrafficConfig()
    • setNetworkTrafficConfig

      @Stability(Stable) public void setNetworkTrafficConfig(@Nullable IResolvable value)
    • setNetworkTrafficConfig

      @Stability(Stable) public void setNetworkTrafficConfig(@Nullable CfnPentest.NetworkTrafficConfigProperty value)
    • getTitle

      @Stability(Stable) @Nullable public String getTitle()
    • setTitle

      @Stability(Stable) public void setTitle(@Nullable String value)
    • getVpcConfig

      @Stability(Stable) @Nullable public Object getVpcConfig()
      Returns union: either IResolvable or CfnPentest.VpcConfigProperty
    • setVpcConfig

      @Stability(Stable) public void setVpcConfig(@Nullable IResolvable value)
    • setVpcConfig

      @Stability(Stable) public void setVpcConfig(@Nullable CfnPentest.VpcConfigProperty value)