Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
RabeaZr committed Nov 5, 2023
1 parent 7b6601f commit 8bbc990
Show file tree
Hide file tree
Showing 8 changed files with 15 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ def __init__(self, scope: core.Construct, id: str, **kwargs) -> None:
"MyDocDBCluster",
db_cluster_identifier="my-docdb-cluster",
master_username="admin",
master_user_password="mypassword",
master_user_password="mypassword", # checkov:skip=CKV_SECRET_6 test secret
availability_zones=["us-east-1a", "us-east-1b"], # Specify the availability zones
port=27017, # Specify the port as needed
)
2 changes: 1 addition & 1 deletion cdk_integration_tests/src/python/DocDBEncryption/pass.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ def __init__(self, scope: core.Construct, id: str, **kwargs) -> None:
"MyDocDBCluster",
db_cluster_identifier="my-docdb-cluster",
master_username="admin",
master_user_password="mypassword",
master_user_password="mypassword", # checkov:skip=CKV_SECRET_6 test secret
storage_encrypted=True, # Enable storage encryption
availability_zones=["us-east-1a", "us-east-1b"], # Specify the availability zones
port=27017, # Specify the port as needed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ def __init__(self, scope: core.Construct, id: str, **kwargs) -> None:
engine="neptune",
db_cluster_identifier="my-neptune-cluster",
master_username="admin",
master_user_password="mypassword",
master_user_password="mypassword", # checkov:skip=CKV_SECRET_6 test secret
storage_encrypted=False, # Enable storage encryption
port=8182, # Specify the port as needed
availability_zones=["us-east-1a", "us-east-1b"], # Specify the availability zones
Expand All @@ -31,7 +31,7 @@ def __init__(self, scope: core.Construct, id: str, **kwargs) -> None:
engine=neptune.DatabaseClusterEngine.NEPTUNE,
master_user=neptune.Login(
username="admin",
password="mypassword",
password="mypassword", # checkov:skip=CKV_SECRET_6 test secret
),
default_database_name="mydb",
removal_policy=core.RemovalPolicy.DESTROY, # Set the removal policy as needed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ def __init__(self, scope: core.Construct, id: str, **kwargs) -> None:
engine="neptune",
db_cluster_identifier="my-neptune-cluster",
master_username="admin",
master_user_password="mypassword",
master_user_password="mypassword", # checkov:skip=CKV_SECRET_6 test secret
storage_encrypted=True, # Enable storage encryption
port=8182, # Specify the port as needed
availability_zones=["us-east-1a", "us-east-1b"], # Specify the availability zones
Expand All @@ -31,7 +31,7 @@ def __init__(self, scope: core.Construct, id: str, **kwargs) -> None:
engine=neptune.DatabaseClusterEngine.NEPTUNE,
master_user=neptune.Login(
username="admin",
password="mypassword",
password="mypassword", # checkov:skip=CKV_SECRET_6 test secret
),
default_database_name="mydb",
storage_encrypted=True, # Enable storage encryption
Expand Down
6 changes: 5 additions & 1 deletion checkov/cdk/checks/python/DAXEncryption.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,8 @@ scope:
definition:
pattern: aws_cdk.aws_dax.CfnCluster(<ANY>)
conditions:
- not_pattern: aws_cdk.aws_dax.CfnCluster(<ANY>, sse_specification=aws_cdk.aws_dax.CfnCluster.SSESpecificationProperty(<ANY>, enabled=True , <ANY>), <ANY>)
- not_pattern: aws_cdk.aws_dax.CfnCluster(<ANY>, sse_specification=aws_cdk.aws_dax.CfnCluster.SSESpecificationProperty(<ANY>, enabled=True , <ANY>), <ANY>)
- not_pattern: |
$P = aws_cdk.aws_dax.CfnCluster.SSESpecificationProperty(<ANY>, enabled=True , <ANY>)
<ANY>
aws_cdk.aws_dax.CfnCluster(sse_specification=$P)
4 changes: 2 additions & 2 deletions checkov/cdk/checks/python/LambdaDLQConfigured.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ definition:
- not_pattern: aws_cdk.aws_lambda.Function(<ANY>, dead_letter_queue=$ARG, <ANY>)
- pattern: aws_cdk.aws_lambda.CfnFunction(<ANY>)
conditions:
- not_pattern: aws_cdk.aws_lambda.CfnFunction(<ANY>, dead_letter_config={<ANY>}, <ANY>)
- not_pattern: aws_cdk.aws_lambda.CfnFunction(<ANY>, dead_letter_config=$ARG, <ANY>)
- pattern: aws_cdk.aws_sam.CfnFunction(<ANY>)
conditions:
- not_pattern: aws_cdk.aws_sam.CfnFunction(<ANY>, dead_letter_queue=aws_cdk.aws_sam.CfnFunction.DeadLetterQueueProperty(<ANY>), <ANY>)
- not_pattern: aws_cdk.aws_sam.CfnFunction(<ANY>, dead_letter_queue=$ARG, <ANY>)
2 changes: 1 addition & 1 deletion checkov/cdk/checks/python/LambdaInVPC.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ definition:
- not_pattern: aws_cdk.aws_lambda.Function(<ANY>, vpc=$VPC, <ANY>)
- pattern: aws_cdk.aws_sam.CfnFunction(<ANY>)
conditions:
- not_pattern: aws_cdk.aws_sam.CfnFunction(<ANY>, vpc_config=aws_cdk.aws_sam.CfnFunction.VpcConfigProperty(<ANY>), <ANY>)
- not_pattern: aws_cdk.aws_sam.CfnFunction(<ANY>, vpc_config=$ARG, <ANY>)
2 changes: 1 addition & 1 deletion checkov/cdk/checks/python/WAFEnabled.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ scope:
definition:
pattern: aws_cdk.aws_cloudfront.CfnDistribution(<ANY>)
conditions:
- not_pattern: 'aws_cdk.aws_cloudfront.CfnDistribution(<ANY>, distribution_config={<ANY>, "webAclId": <ANY> , <ANY>} , <ANY>)'
- not_pattern: 'aws_cdk.aws_cloudfront.CfnDistribution(<ANY>, distribution_config={"webAclId": $ARG} , <ANY>)'

0 comments on commit 8bbc990

Please sign in to comment.