diff --git a/docs/format_keyword.md b/docs/format_keyword.md index 027c4930b5..20b016ed22 100644 --- a/docs/format_keyword.md +++ b/docs/format_keyword.md @@ -12,14 +12,22 @@ In `cfn-lint`, we have extended the `format` keyword to support custom formats t This format ensures that the value is a valid VPC ID, which is a string of the pattern `vpc-[0-9a-f]{8}` or `vpc-[0-9a-f]{17}`. -### AWS::EC2::SecurityGroup.GroupId +### AWS::EC2::SecurityGroup.Id This format validates that the value is a valid Security Group ID, which is a string of the pattern `sg-[0-9a-f]{8}` or `sg-[0-9a-f]{17}`. -### AWS::EC2::SecurityGroup.GroupName +### AWS::EC2::SecurityGroup.Ids + +This format validates that the value is a valid list of Security Group IDs, which is a string of the pattern `sg-[0-9a-f]{8}` or `sg-[0-9a-f]{17}`. + +### AWS::EC2::SecurityGroup.Name This format validates that the value is a valid Security Group Name, which must be a string of 1 to 255 characters, starting with a letter, and containing only letters, numbers, and certain special characters. ### AWS::EC2::Image.Id This format validates that the value is a valid Amazon Machine Image (AMI), which is a string of the pattern `ami-[0-9a-f]{8}` or `ami-[0-9a-f]{17}`. More info in [docs](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/resource-ids.html) + +### AWS::Logs::LogGroup.Name + +This format validates that the value is a valid log group name, which is a string of the pattern `^[\.\-_\/#A-Za-z0-9]{1,512}\Z`. More info in [docs](https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_LogGroup.html) diff --git a/scripts/update_schemas_format.py b/scripts/update_schemas_format.py index ce04bd7fad..fbf65c6ffa 100755 --- a/scripts/update_schemas_format.py +++ b/scripts/update_schemas_format.py @@ -76,6 +76,8 @@ def _create_security_group_ids_patch(type_name: str, ref: str, resolver: RefReso ref=resolved["$ref"], resolver=resolver, ) + if resolved.get("type") != "array": + return [] items = resolved.get("items") if items: if "$ref" in items: @@ -89,7 +91,7 @@ def _create_security_group_ids_patch(type_name: str, ref: str, resolver: RefReso path=ref[1:], ), _create_patch( - {"format": "AWS::EC2::SecurityGroup.GroupId"}, + {"format": "AWS::EC2::SecurityGroup.Id"}, items_path, resolver=resolver, ), @@ -110,7 +112,7 @@ def _create_security_group_id(type_name: str, ref: str, resolver: RefResolver): return [ _create_patch( - {"format": "AWS::EC2::SecurityGroup.GroupId"}, + {"format": "AWS::EC2::SecurityGroup.Id"}, ref, resolver=resolver, ) @@ -129,7 +131,7 @@ def _create_security_group_name(type_name: str, ref: str, resolver: RefResolver) return [ _create_patch( - {"format": "AWS::EC2::SecurityGroup.GroupName"}, + {"format": "AWS::EC2::SecurityGroup.Name"}, ref, resolver=resolver, ) @@ -150,23 +152,32 @@ def _create_patch(value: dict[str, str], ref: Sequence[str], resolver: RefResolv _manual_patches = { "AWS::EC2::SecurityGroup": [ Patch( - values={"format": "AWS::EC2::SecurityGroup.GroupId"}, + values={"format": "AWS::EC2::SecurityGroup.Id"}, path="/properties/GroupId", ), Patch( - values={"format": "AWS::EC2::SecurityGroup.GroupName"}, + values={"format": "AWS::EC2::SecurityGroup.Name"}, path="/properties/GroupName", ), + Patch( + values={ + "anyOf": [ + {"format": "AWS::EC2::SecurityGroup.Id"}, + {"format": "AWS::EC2::SecurityGroup.Name"}, + ] + }, + path="/properties/Id", + ), ], "AWS::EC2::SecurityGroupIngress": [ Patch( - values={"format": "AWS::EC2::SecurityGroup.GroupId"}, + values={"format": "AWS::EC2::SecurityGroup.Id"}, path="/properties/GroupId", ), ], "AWS::EC2::SecurityGroupEgress": [ Patch( - values={"format": "AWS::EC2::SecurityGroup.GroupId"}, + values={"format": "AWS::EC2::SecurityGroup.Id"}, path="/properties/GroupId", ), ], @@ -231,7 +242,30 @@ def main(): ) ) - for path in _descend(obj, ["SecurityGroupIds", "SecurityGroups"]): + for path in _descend(obj, ["LogGroupName"]): + if path[-2] == "properties": + resource_patches.append( + _create_patch( + value={"format": "AWS::Logs::LogGroup.Name"}, + ref="#/" + "/".join(path), + resolver=resolver, + ) + ) + + for path in _descend( + obj, + [ + "CustomSecurityGroupIds", + "DBSecurityGroups", + "Ec2SecurityGroupIds", + "GroupSet", + "InputSecurityGroups", + "SecurityGroupIdList", + "SecurityGroupIds", + "SecurityGroups", + "VpcSecurityGroupIds", + ], + ): if path[-2] == "properties": resource_patches.extend( _create_security_group_ids_patch( @@ -242,11 +276,14 @@ def main(): for path in _descend( obj, [ + "ClusterSecurityGroupId", "DefaultSecurityGroup", - "SourceSecurityGroupId", "DestinationSecurityGroupId", + "EC2SecurityGroupId", "SecurityGroup", "SecurityGroupId", + "SecurityGroupIngress" "SourceSecurityGroupId", + "VpcSecurityGroupId", ], ): if path[-2] == "properties": @@ -259,7 +296,11 @@ def main(): for path in _descend( obj, [ - "SourceSecurityGroupName", + "CacheSecurityGroupName", + "ClusterSecurityGroupName", + "DBSecurityGroupName", + "EC2SecurityGroupName", + "SourceSecurityGroupName" "SourceSecurityGroupName", ], ): if path[-2] == "properties": diff --git a/scripts/update_snapshot_results.sh b/scripts/update_snapshot_results.sh index 98c0f00a69..a9b506f677 100755 --- a/scripts/update_snapshot_results.sh +++ b/scripts/update_snapshot_results.sh @@ -6,6 +6,8 @@ cfn-lint test/fixtures/templates/integration/resources-cloudformation-init.yaml cfn-lint test/fixtures/templates/integration/ref-no-value.yaml -e -c I --format json > test/fixtures/results/integration/ref-no-value.json cfn-lint test/fixtures/templates/integration/availability-zones.yaml -e -c I --format json > test/fixtures/results/integration/availability-zones.json cfn-lint test/fixtures/templates/integration/getatt-types.yaml -e -c I --format json > test/fixtures/results/integration/getatt-types.json +cfn-lint test/fixtures/templates/integration/ref-types.yaml -e -c I --format json > test/fixtures/results/integration/ref-types.json +cfn-lint test/fixtures/templates/integration/formats.yaml -e -c I --format json > test/fixtures/results/integration/formats.json cfn-lint test/fixtures/templates/integration/aws-ec2-networkinterface.yaml -e -c I --format json > test/fixtures/results/integration/aws-ec2-networkinterface.json cfn-lint test/fixtures/templates/integration/aws-ec2-instance.yaml -e -c I --format json > test/fixtures/results/integration/aws-ec2-instance.json cfn-lint test/fixtures/templates/integration/aws-ec2-launchtemplate.yaml -e -c I --format json > test/fixtures/results/integration/aws-ec2-launchtemplate.json diff --git a/src/cfnlint/context/context.py b/src/cfnlint/context/context.py index a8c9f073e8..ab99f90a73 100644 --- a/src/cfnlint/context/context.py +++ b/src/cfnlint/context/context.py @@ -198,7 +198,7 @@ def ref_value(self, instance: str) -> Iterator[Tuple[str | list[str], "Context"] yield pseudo_value, self.evolve(ref_values={instance: pseudo_value}) return if instance in self.parameters: - for v, path in self.parameters[instance].ref(self): + for v, path in self.parameters[instance].ref_value(self): # validate that ref is possible with path # need to evaluate if Fn::If would be not true if value is @@ -278,7 +278,11 @@ class _Ref(ABC): """ @abstractmethod - def ref(self, context: Context) -> Iterator[Any]: + def ref(self, region: str) -> dict[str, Any]: + pass + + @abstractmethod + def ref_value(self, context: Context) -> Iterator[Tuple[Any, deque]]: pass @@ -351,7 +355,10 @@ def __post_init__(self, parameter) -> None: if parameter.get("NoEcho") in list(BOOLEAN_STRINGS_TRUE) + [True]: self.no_echo = True - def ref(self, context: Context) -> Iterator[Tuple[Any, deque]]: + def ref(self, region: str = REGION_PRIMARY) -> dict[str, Any]: + return {} + + def ref_value(self, context: Context) -> Iterator[Tuple[Any, deque]]: if self.allowed_values: for i, allowed_value in enumerate(self.allowed_values): if isinstance(allowed_value, list): @@ -402,10 +409,13 @@ def __post_init__(self, resource) -> None: raise ValueError("Condition must be a string") self.condition = c - def get_atts(self, region: str = "us-east-1") -> AttributeDict: + def get_atts(self, region: str = REGION_PRIMARY) -> AttributeDict: return PROVIDER_SCHEMA_MANAGER.get_type_getatts(self.type, region) - def ref(self, context: Context) -> Iterator[Any]: + def ref(self, region: str = REGION_PRIMARY) -> dict[str, Any]: + return PROVIDER_SCHEMA_MANAGER.get_type_ref(self.type, region) + + def ref_value(self, context: Context) -> Iterator[Tuple[Any, deque]]: return yield diff --git a/src/cfnlint/data/schemas/extensions/aws_ecs_taskdefinition/logging_configuration.json b/src/cfnlint/data/schemas/extensions/aws_ecs_taskdefinition/logging_configuration.json index 0fd51903c8..04061f3c5a 100644 --- a/src/cfnlint/data/schemas/extensions/aws_ecs_taskdefinition/logging_configuration.json +++ b/src/cfnlint/data/schemas/extensions/aws_ecs_taskdefinition/logging_configuration.json @@ -14,6 +14,12 @@ "then": { "properties": { "Options": { + "properties": { + "awslogs-group": { + "format": "AWS::Logs::LogGroup.Name", + "type": "string" + } + }, "propertyNames": { "enum": [ "awslogs-create-group", diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_amazonmq_broker/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_amazonmq_broker/format.json index 182adadf4f..dbc05cd2b5 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_amazonmq_broker/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_amazonmq_broker/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_apigatewayv2_vpclink/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_apigatewayv2_vpclink/format.json index f7bdf7d24a..aeb37b6d7f 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_apigatewayv2_vpclink/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_apigatewayv2_vpclink/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_applicationinsights_application/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_applicationinsights_application/format.json new file mode 100644 index 0000000000..8ecef139ff --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_applicationinsights_application/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/definitions/Log/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + }, + { + "op": "add", + "path": "/definitions/WindowsEvent/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_apprunner_vpcconnector/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_apprunner_vpcconnector/format.json index 3cda037083..ee686949f9 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_apprunner_vpcconnector/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_apprunner_vpcconnector/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_appstream_appblockbuilder/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_appstream_appblockbuilder/format.json index bfba77bf8a..c58cc2445b 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_appstream_appblockbuilder/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_appstream_appblockbuilder/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_appstream_fleet/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_appstream_fleet/format.json index bfba77bf8a..c58cc2445b 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_appstream_fleet/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_appstream_fleet/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_appstream_imagebuilder/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_appstream_imagebuilder/format.json index bfba77bf8a..c58cc2445b 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_appstream_imagebuilder/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_appstream_imagebuilder/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_aps_scraper/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_aps_scraper/format.json index b437fe02b5..b9c5719169 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_aps_scraper/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_aps_scraper/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/SecurityGroupId/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_autoscaling_launchconfiguration/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_autoscaling_launchconfiguration/format.json index 92c07191b3..5ace751082 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_autoscaling_launchconfiguration/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_autoscaling_launchconfiguration/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_b2bi_profile/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_b2bi_profile/format.json new file mode 100644 index 0000000000..137291e3e0 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_b2bi_profile/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_batch_computeenvironment/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_batch_computeenvironment/format.json index eb1e225dc3..c61a5cd6e9 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_batch_computeenvironment/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_batch_computeenvironment/format.json @@ -22,6 +22,6 @@ { "op": "add", "path": "/definitions/ComputeResources/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_cloudformation_hookversion/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_cloudformation_hookversion/format.json new file mode 100644 index 0000000000..b55da3f58b --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_cloudformation_hookversion/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/definitions/LoggingConfig/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_cloudformation_macro/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_cloudformation_macro/format.json new file mode 100644 index 0000000000..137291e3e0 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_cloudformation_macro/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_cloudformation_resourceversion/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_cloudformation_resourceversion/format.json new file mode 100644 index 0000000000..b55da3f58b --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_cloudformation_resourceversion/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/definitions/LoggingConfig/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_cloudformation_typeactivation/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_cloudformation_typeactivation/format.json new file mode 100644 index 0000000000..b55da3f58b --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_cloudformation_typeactivation/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/definitions/LoggingConfig/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_codebuild_fleet/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_codebuild_fleet/format.json index b2eb6ce3e6..c38dfb0c87 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_codebuild_fleet/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_codebuild_fleet/format.json @@ -27,6 +27,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_codebuild_project/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_codebuild_project/format.json index e06d242c3f..d635432486 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_codebuild_project/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_codebuild_project/format.json @@ -22,6 +22,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_comprehend_documentclassifier/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_comprehend_documentclassifier/format.json index 5dfc55f740..3f5bb4c994 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_comprehend_documentclassifier/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_comprehend_documentclassifier/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_comprehend_flywheel/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_comprehend_flywheel/format.json index 5dfc55f740..3f5bb4c994 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_comprehend_flywheel/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_comprehend_flywheel/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_dax_cluster/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_dax_cluster/format.json index f7bdf7d24a..aeb37b6d7f 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_dax_cluster/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_dax_cluster/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_deadline_licenseendpoint/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_deadline_licenseendpoint/format.json index e04f2b212c..7188467212 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_deadline_licenseendpoint/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_deadline_licenseendpoint/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_dms_replicationconfig/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_dms_replicationconfig/format.json new file mode 100644 index 0000000000..391822a8e9 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_dms_replicationconfig/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/definitions/ComputeConfig/properties/VpcSecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/definitions/ComputeConfig/properties/VpcSecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_dms_replicationinstance/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_dms_replicationinstance/format.json new file mode 100644 index 0000000000..12577f9775 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_dms_replicationinstance/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_docdb_dbcluster/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_docdb_dbcluster/format.json new file mode 100644 index 0000000000..12577f9775 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_docdb_dbcluster/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_docdbelastic_cluster/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_docdbelastic_cluster/format.json new file mode 100644 index 0000000000..12577f9775 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_docdbelastic_cluster/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_clientvpnendpoint/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_clientvpnendpoint/format.json index e04f2b212c..7188467212 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_clientvpnendpoint/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_clientvpnendpoint/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_flowlog/__init__.py b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_flowlog/__init__.py new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_flowlog/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_flowlog/format.json new file mode 100644 index 0000000000..137291e3e0 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_flowlog/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_instance/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_instance/format.json index d4732e9149..3cb22c0fdb 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_instance/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_instance/format.json @@ -19,6 +19,16 @@ "path": "/properties/SubnetId/format", "value": "AWS::EC2::Subnet.Id" }, + { + "op": "add", + "path": "/definitions/NetworkInterface/properties/GroupSet/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/definitions/NetworkInterface/properties/GroupSet/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + }, { "op": "add", "path": "/properties/SecurityGroupIds/format", @@ -27,7 +37,7 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" }, { "op": "add", @@ -37,6 +47,6 @@ { "op": "add", "path": "/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_instanceconnectendpoint/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_instanceconnectendpoint/format.json index 2699321c7a..e5b9d3b1aa 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_instanceconnectendpoint/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_instanceconnectendpoint/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/definitions/SecurityGroupId/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_launchtemplate/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_launchtemplate/format.json index a5dd048dda..bfb0a911af 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_launchtemplate/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_launchtemplate/format.json @@ -17,7 +17,7 @@ { "op": "add", "path": "/definitions/LaunchTemplateData/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" }, { "op": "add", @@ -27,6 +27,6 @@ { "op": "add", "path": "/definitions/LaunchTemplateData/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_networkinterface/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_networkinterface/format.json index f3c5c0f525..4e083e39f9 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_networkinterface/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_networkinterface/format.json @@ -8,5 +8,15 @@ "op": "add", "path": "/properties/SubnetId/format", "value": "AWS::EC2::Subnet.Id" + }, + { + "op": "add", + "path": "/properties/GroupSet/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/GroupSet/items/format", + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_securitygroup/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_securitygroup/format.json index fb4ecb5172..c1a74cc5e8 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_securitygroup/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_securitygroup/format.json @@ -2,12 +2,24 @@ { "op": "add", "path": "/properties/GroupId/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" }, { "op": "add", "path": "/properties/GroupName/format", - "value": "AWS::EC2::SecurityGroup.GroupName" + "value": "AWS::EC2::SecurityGroup.Name" + }, + { + "op": "add", + "path": "/properties/Id/anyOf", + "value": [ + { + "format": "AWS::EC2::SecurityGroup.Id" + }, + { + "format": "AWS::EC2::SecurityGroup.Name" + } + ] }, { "op": "add", @@ -17,16 +29,16 @@ { "op": "add", "path": "/definitions/Egress/properties/DestinationSecurityGroupId/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" }, { "op": "add", "path": "/definitions/Ingress/properties/SourceSecurityGroupId/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" }, { "op": "add", "path": "/definitions/Ingress/properties/SourceSecurityGroupName/format", - "value": "AWS::EC2::SecurityGroup.GroupName" + "value": "AWS::EC2::SecurityGroup.Name" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_securitygroupegress/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_securitygroupegress/format.json index 7a9c06bff8..10a0bbd79f 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_securitygroupegress/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_securitygroupegress/format.json @@ -2,11 +2,11 @@ { "op": "add", "path": "/properties/GroupId/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" }, { "op": "add", "path": "/properties/DestinationSecurityGroupId/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_securitygroupingress/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_securitygroupingress/format.json index da6d0c8663..c7c47e9bb0 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_securitygroupingress/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_securitygroupingress/format.json @@ -2,16 +2,16 @@ { "op": "add", "path": "/properties/GroupId/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" }, { "op": "add", "path": "/properties/SourceSecurityGroupId/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" }, { "op": "add", "path": "/properties/SourceSecurityGroupName/format", - "value": "AWS::EC2::SecurityGroup.GroupName" + "value": "AWS::EC2::SecurityGroup.Name" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_spotfleet/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_spotfleet/format.json index 55b97d8afc..c40d215e41 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_spotfleet/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_spotfleet/format.json @@ -27,6 +27,6 @@ { "op": "add", "path": "/definitions/GroupIdentifier/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_verifiedaccessendpoint/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_verifiedaccessendpoint/format.json index 24b4bcaa67..bd21c14802 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_verifiedaccessendpoint/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_verifiedaccessendpoint/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/SecurityGroupId/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_vpc/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_vpc/format.json index f755bb6370..f017ab7eb3 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_vpc/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_vpc/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/properties/DefaultSecurityGroup/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_vpcendpoint/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_vpcendpoint/format.json index e04f2b212c..7188467212 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_vpcendpoint/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ec2_vpcendpoint/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ecs_service/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ecs_service/format.json index ab938a08e4..d52789ac36 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ecs_service/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ecs_service/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/AwsVpcConfiguration/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ecs_taskset/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ecs_taskset/format.json index ab938a08e4..d52789ac36 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_ecs_taskset/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ecs_taskset/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/AwsVpcConfiguration/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_efs_mounttarget/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_efs_mounttarget/format.json index 306d92d48b..77dba2a42e 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_efs_mounttarget/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_efs_mounttarget/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_eks_cluster/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_eks_cluster/format.json index f5980829f2..771f5080e8 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_eks_cluster/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_eks_cluster/format.json @@ -7,6 +7,11 @@ { "op": "add", "path": "/definitions/ResourcesVpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" + }, + { + "op": "add", + "path": "/properties/ClusterSecurityGroupId/format", + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticache_cachecluster/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticache_cachecluster/format.json new file mode 100644 index 0000000000..12577f9775 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticache_cachecluster/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticache_replicationgroup/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticache_replicationgroup/format.json index f7bdf7d24a..aeb37b6d7f 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticache_replicationgroup/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticache_replicationgroup/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticache_serverlesscache/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticache_serverlesscache/format.json index f7bdf7d24a..aeb37b6d7f 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticache_serverlesscache/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticache_serverlesscache/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticloadbalancing_loadbalancer/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticloadbalancing_loadbalancer/format.json index 3cda037083..ee686949f9 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticloadbalancing_loadbalancer/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticloadbalancing_loadbalancer/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticloadbalancingv2_loadbalancer/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticloadbalancingv2_loadbalancer/format.json index 8b3b9f72ea..d010fbd9c5 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticloadbalancingv2_loadbalancer/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticloadbalancingv2_loadbalancer/format.json @@ -22,6 +22,6 @@ { "op": "add", "path": "/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticsearch_domain/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticsearch_domain/format.json index e1f707feda..0a591757a1 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticsearch_domain/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_elasticsearch_domain/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/VPCOptions/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_emrserverless_application/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_emrserverless_application/format.json index 3da4c454a3..b7f60a5e9c 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_emrserverless_application/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_emrserverless_application/format.json @@ -1,4 +1,9 @@ [ + { + "op": "add", + "path": "/definitions/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + }, { "op": "add", "path": "/definitions/NetworkConfiguration/properties/SecurityGroupIds/format", @@ -7,6 +12,6 @@ { "op": "add", "path": "/definitions/SecurityGroupId/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_events_rule/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_events_rule/format.json index ab938a08e4..d52789ac36 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_events_rule/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_events_rule/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/AwsVpcConfiguration/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_fsx_filesystem/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_fsx_filesystem/format.json index f7bdf7d24a..aeb37b6d7f 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_fsx_filesystem/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_fsx_filesystem/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_glue_connection/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_glue_connection/format.json index 0600752957..8ec2e265f7 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_glue_connection/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_glue_connection/format.json @@ -3,5 +3,15 @@ "op": "add", "path": "/definitions/PhysicalConnectionRequirements/properties/SubnetId/format", "value": "AWS::EC2::Subnet.Id" + }, + { + "op": "add", + "path": "/definitions/PhysicalConnectionRequirements/properties/SecurityGroupIdList/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/definitions/PhysicalConnectionRequirements/properties/SecurityGroupIdList/items/format", + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_glue_devendpoint/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_glue_devendpoint/format.json index 49c2218f19..3e45820a49 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_glue_devendpoint/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_glue_devendpoint/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_grafana_workspace/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_grafana_workspace/format.json index fd394d823a..6f39ac6cba 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_grafana_workspace/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_grafana_workspace/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/VpcConfiguration/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_groundstation_dataflowendpointgroup/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_groundstation_dataflowendpointgroup/format.json index a0ebee9271..c036991b68 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_groundstation_dataflowendpointgroup/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_groundstation_dataflowendpointgroup/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/SecurityDetails/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_imagebuilder_infrastructureconfiguration/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_imagebuilder_infrastructureconfiguration/format.json index 49c2218f19..3e45820a49 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_imagebuilder_infrastructureconfiguration/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_imagebuilder_infrastructureconfiguration/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_iot_topicrule/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_iot_topicrule/format.json new file mode 100644 index 0000000000..cea5311993 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_iot_topicrule/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/definitions/CloudwatchLogsAction/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_iot_topicruledestination/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_iot_topicruledestination/format.json index c05356b3c4..1d170721e3 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_iot_topicruledestination/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_iot_topicruledestination/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/definitions/VpcDestinationProperties/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_ivschat_loggingconfiguration/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_ivschat_loggingconfiguration/format.json new file mode 100644 index 0000000000..024712c8f7 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_ivschat_loggingconfiguration/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/definitions/CloudWatchLogsDestinationConfiguration/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_kafkaconnect_connector/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_kafkaconnect_connector/format.json index 99d8a6cd0c..7eb63031f7 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_kafkaconnect_connector/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_kafkaconnect_connector/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/Vpc/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_kendra_datasource/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_kendra_datasource/format.json index 75b236ab63..f863f24314 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_kendra_datasource/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_kendra_datasource/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/DataSourceVpcConfiguration/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_kinesisanalyticsv2_application/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_kinesisanalyticsv2_application/format.json index fd394d823a..6f39ac6cba 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_kinesisanalyticsv2_application/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_kinesisanalyticsv2_application/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/VpcConfiguration/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_kinesisfirehose_deliverystream/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_kinesisfirehose_deliverystream/format.json index fd394d823a..848cb3fd30 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_kinesisfirehose_deliverystream/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_kinesisfirehose_deliverystream/format.json @@ -1,4 +1,9 @@ [ + { + "op": "add", + "path": "/definitions/CloudWatchLoggingOptions/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + }, { "op": "add", "path": "/definitions/VpcConfiguration/properties/SecurityGroupIds/format", @@ -7,6 +12,6 @@ { "op": "add", "path": "/definitions/VpcConfiguration/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_lambda_function/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_lambda_function/format.json index bfba77bf8a..c58cc2445b 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_lambda_function/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_lambda_function/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_logs_loggroup/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_logs_loggroup/format.json new file mode 100644 index 0000000000..137291e3e0 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_logs_loggroup/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_logs_logstream/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_logs_logstream/format.json new file mode 100644 index 0000000000..137291e3e0 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_logs_logstream/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_logs_metricfilter/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_logs_metricfilter/format.json new file mode 100644 index 0000000000..137291e3e0 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_logs_metricfilter/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_logs_subscriptionfilter/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_logs_subscriptionfilter/format.json new file mode 100644 index 0000000000..137291e3e0 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_logs_subscriptionfilter/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_lookoutmetrics_anomalydetector/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_lookoutmetrics_anomalydetector/format.json new file mode 100644 index 0000000000..6f9ce8631f --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_lookoutmetrics_anomalydetector/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/definitions/SecurityGroupIdList/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/definitions/SecurityGroupIdList/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_m2_environment/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_m2_environment/format.json index f7bdf7d24a..aeb37b6d7f 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_m2_environment/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_m2_environment/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_mediaconnect_flow/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_mediaconnect_flow/format.json index 4a7f180e09..26f271ba78 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_mediaconnect_flow/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_mediaconnect_flow/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/definitions/VpcInterface/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_mediaconnect_flowvpcinterface/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_mediaconnect_flowvpcinterface/format.json index 49c2218f19..3e45820a49 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_mediaconnect_flowvpcinterface/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_mediaconnect_flowvpcinterface/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_medialive_channel/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_medialive_channel/format.json index 94fa22cf04..1444a6e2f6 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_medialive_channel/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_medialive_channel/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/VpcOutputSettings/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_medialive_input/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_medialive_input/format.json index dbf26e4b40..5fb1f361fc 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_medialive_input/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_medialive_input/format.json @@ -7,6 +7,16 @@ { "op": "add", "path": "/definitions/InputVpcRequest/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" + }, + { + "op": "add", + "path": "/properties/InputSecurityGroups/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/InputSecurityGroups/items/format", + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_mediapackage_channel/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_mediapackage_channel/format.json new file mode 100644 index 0000000000..8367c1731e --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_mediapackage_channel/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/definitions/LogConfiguration/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_mediapackage_packaginggroup/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_mediapackage_packaginggroup/format.json new file mode 100644 index 0000000000..8367c1731e --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_mediapackage_packaginggroup/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/definitions/LogConfiguration/properties/LogGroupName/format", + "value": "AWS::Logs::LogGroup.Name" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_memorydb_cluster/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_memorydb_cluster/format.json index f7bdf7d24a..aeb37b6d7f 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_memorydb_cluster/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_memorydb_cluster/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_cluster/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_cluster/format.json index 0490dc5546..8f7dde96b1 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_cluster/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_cluster/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/BrokerNodeGroupInfo/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_replicator/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_replicator/format.json index 60016069f7..be41ad2721 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_replicator/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_replicator/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/KafkaClusterClientVpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_serverlesscluster/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_serverlesscluster/format.json index c3753be708..3a92f68a33 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_serverlesscluster/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_serverlesscluster/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_vpcconnection/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_vpcconnection/format.json index e5a30e13f2..0fe43e9755 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_vpcconnection/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_msk_vpcconnection/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/definitions/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_mwaa_environment/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_mwaa_environment/format.json index 3da4c454a3..34030950ea 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_mwaa_environment/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_mwaa_environment/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/SecurityGroupId/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_neptune_dbcluster/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_neptune_dbcluster/format.json new file mode 100644 index 0000000000..12577f9775 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_neptune_dbcluster/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_neptunegraph_privategraphendpoint/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_neptunegraph_privategraphendpoint/format.json index e04f2b212c..7188467212 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_neptunegraph_privategraphendpoint/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_neptunegraph_privategraphendpoint/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_nimblestudio_studiocomponent/__init__.py b/src/cfnlint/data/schemas/patches/extensions/all/aws_nimblestudio_studiocomponent/__init__.py new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_nimblestudio_studiocomponent/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_nimblestudio_studiocomponent/format.json new file mode 100644 index 0000000000..eb3533aa21 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_nimblestudio_studiocomponent/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/properties/Ec2SecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/Ec2SecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_opensearchserverless_vpcendpoint/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_opensearchserverless_vpcendpoint/format.json index e04f2b212c..7188467212 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_opensearchserverless_vpcendpoint/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_opensearchserverless_vpcendpoint/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_opensearchservice_domain/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_opensearchservice_domain/format.json index e1f707feda..0a591757a1 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_opensearchservice_domain/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_opensearchservice_domain/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/VPCOptions/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_opsworks_layer/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_opsworks_layer/format.json new file mode 100644 index 0000000000..f01a129b6b --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_opsworks_layer/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/properties/CustomSecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/CustomSecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_opsworkscm_server/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_opsworkscm_server/format.json index f7bdf7d24a..aeb37b6d7f 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_opsworkscm_server/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_opsworkscm_server/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_osis_pipeline/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_osis_pipeline/format.json index eee9248ff0..15757b0fca 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_osis_pipeline/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_osis_pipeline/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/definitions/VpcOptions/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_pcaconnectorad_connector/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_pcaconnectorad_connector/format.json index 866ea2c41c..e98516e9e4 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_pcaconnectorad_connector/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_pcaconnectorad_connector/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/VpcInformation/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_pcs_cluster/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_pcs_cluster/format.json new file mode 100644 index 0000000000..4a158f693b --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_pcs_cluster/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/properties/Networking/properties/SecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/definitions/SecurityGroupId/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_pcs_computenodegroup/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_pcs_computenodegroup/format.json new file mode 100644 index 0000000000..7d3cf7cf72 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_pcs_computenodegroup/format.json @@ -0,0 +1,7 @@ +[ + { + "op": "add", + "path": "/properties/AmiId/format", + "value": "AWS::EC2::Image.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_qbusiness_datasource/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_qbusiness_datasource/format.json index 75b236ab63..f863f24314 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_qbusiness_datasource/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_qbusiness_datasource/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/DataSourceVpcConfiguration/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_quicksight_vpcconnection/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_quicksight_vpcconnection/format.json index 2e003f656b..4398c9eb66 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_quicksight_vpcconnection/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_quicksight_vpcconnection/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_rds_dbcluster/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_rds_dbcluster/format.json new file mode 100644 index 0000000000..12577f9775 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_rds_dbcluster/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_rds_dbproxy/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_rds_dbproxy/format.json index b477cfe8f7..3865ff05d5 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_rds_dbproxy/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_rds_dbproxy/format.json @@ -3,5 +3,15 @@ "op": "add", "path": "/properties/VpcId/format", "value": "AWS::EC2::VPC.Id" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_rds_dbproxyendpoint/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_rds_dbproxyendpoint/format.json index b477cfe8f7..3865ff05d5 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_rds_dbproxyendpoint/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_rds_dbproxyendpoint/format.json @@ -3,5 +3,15 @@ "op": "add", "path": "/properties/VpcId/format", "value": "AWS::EC2::VPC.Id" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_redshift_cluster/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_redshift_cluster/format.json new file mode 100644 index 0000000000..12577f9775 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_redshift_cluster/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_redshift_endpointaccess/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_redshift_endpointaccess/format.json index 913488203f..4df8085630 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_redshift_endpointaccess/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_redshift_endpointaccess/format.json @@ -8,5 +8,20 @@ "op": "add", "path": "/definitions/NetworkInterface/properties/SubnetId/format", "value": "AWS::EC2::Subnet.Id" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + }, + { + "op": "add", + "path": "/definitions/VpcSecurityGroup/properties/VpcSecurityGroupId/format", + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_redshiftserverless_workgroup/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_redshiftserverless_workgroup/format.json index bb7d1dff89..2747301d2e 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_redshiftserverless_workgroup/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_redshiftserverless_workgroup/format.json @@ -17,7 +17,7 @@ { "op": "add", "path": "/definitions/Workgroup/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" }, { "op": "add", @@ -27,6 +27,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_route53resolver_resolverendpoint/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_route53resolver_resolverendpoint/format.json index 493cb52cd5..e4d950690a 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_route53resolver_resolverendpoint/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_route53resolver_resolverendpoint/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_s3outposts_endpoint/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_s3outposts_endpoint/format.json index 9369cdcb66..6f905180e6 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_s3outposts_endpoint/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_s3outposts_endpoint/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/properties/SecurityGroupId/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_cluster/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_cluster/format.json index 5dfc55f740..3f5bb4c994 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_cluster/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_cluster/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_dataqualityjobdefinition/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_dataqualityjobdefinition/format.json index 5dfc55f740..3f5bb4c994 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_dataqualityjobdefinition/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_dataqualityjobdefinition/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_domain/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_domain/format.json index 2112f3775f..fbf35e727b 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_domain/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_domain/format.json @@ -12,7 +12,7 @@ { "op": "add", "path": "/definitions/DefaultSpaceSettings/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" }, { "op": "add", @@ -22,7 +22,7 @@ { "op": "add", "path": "/definitions/DomainSettings/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" }, { "op": "add", @@ -32,6 +32,6 @@ { "op": "add", "path": "/definitions/UserSettings/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_endpointconfig/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_endpointconfig/format.json index 5dfc55f740..3f5bb4c994 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_endpointconfig/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_endpointconfig/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_model/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_model/format.json index 5dfc55f740..3f5bb4c994 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_model/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_model/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_modelbiasjobdefinition/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_modelbiasjobdefinition/format.json index 5dfc55f740..3f5bb4c994 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_modelbiasjobdefinition/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_modelbiasjobdefinition/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_modelexplainabilityjobdefinition/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_modelexplainabilityjobdefinition/format.json index 5dfc55f740..3f5bb4c994 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_modelexplainabilityjobdefinition/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_modelexplainabilityjobdefinition/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_modelqualityjobdefinition/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_modelqualityjobdefinition/format.json index 5dfc55f740..3f5bb4c994 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_modelqualityjobdefinition/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_modelqualityjobdefinition/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_monitoringschedule/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_monitoringschedule/format.json index 5dfc55f740..3f5bb4c994 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_monitoringschedule/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_monitoringschedule/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/VpcConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_notebookinstance/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_notebookinstance/format.json index 49c2218f19..3e45820a49 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_notebookinstance/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_notebookinstance/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_userprofile/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_userprofile/format.json index 9dc6131a1f..45c1df07e7 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_userprofile/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_sagemaker_userprofile/format.json @@ -7,6 +7,6 @@ { "op": "add", "path": "/definitions/UserSettings/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_scheduler_schedule/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_scheduler_schedule/format.json index ab938a08e4..d52789ac36 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_scheduler_schedule/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_scheduler_schedule/format.json @@ -17,6 +17,6 @@ { "op": "add", "path": "/definitions/AwsVpcConfiguration/properties/SecurityGroups/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_synthetics_canary/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_synthetics_canary/format.json index 7896b0e306..f9671f3b35 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_synthetics_canary/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_synthetics_canary/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/definitions/VPCConfig/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_timestream_influxdbinstance/__init__.py b/src/cfnlint/data/schemas/patches/extensions/all/aws_timestream_influxdbinstance/__init__.py new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_timestream_influxdbinstance/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_timestream_influxdbinstance/format.json new file mode 100644 index 0000000000..12577f9775 --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_timestream_influxdbinstance/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/VpcSecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_transfer_server/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_transfer_server/format.json index ee0367829f..cbd9006eff 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_transfer_server/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_transfer_server/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/definitions/EndpointDetails/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_vpclattice_resourcegateway/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_vpclattice_resourcegateway/format.json new file mode 100644 index 0000000000..aeb37b6d7f --- /dev/null +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_vpclattice_resourcegateway/format.json @@ -0,0 +1,12 @@ +[ + { + "op": "add", + "path": "/properties/SecurityGroupIds/format", + "value": "AWS::EC2::SecurityGroup.Ids" + }, + { + "op": "add", + "path": "/properties/SecurityGroupIds/items/format", + "value": "AWS::EC2::SecurityGroup.Id" + } +] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_vpclattice_servicenetworkvpcassociation/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_vpclattice_servicenetworkvpcassociation/format.json index e04f2b212c..7188467212 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_vpclattice_servicenetworkvpcassociation/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_vpclattice_servicenetworkvpcassociation/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/extensions/all/aws_workspacesweb_networksettings/format.json b/src/cfnlint/data/schemas/patches/extensions/all/aws_workspacesweb_networksettings/format.json index e04f2b212c..7188467212 100644 --- a/src/cfnlint/data/schemas/patches/extensions/all/aws_workspacesweb_networksettings/format.json +++ b/src/cfnlint/data/schemas/patches/extensions/all/aws_workspacesweb_networksettings/format.json @@ -12,6 +12,6 @@ { "op": "add", "path": "/properties/SecurityGroupIds/items/format", - "value": "AWS::EC2::SecurityGroup.GroupId" + "value": "AWS::EC2::SecurityGroup.Id" } ] diff --git a/src/cfnlint/data/schemas/patches/providers/all/aws_elasticloadbalancing_loadbalancer/readonlyproperties.json b/src/cfnlint/data/schemas/patches/providers/all/aws_elasticloadbalancing_loadbalancer/readonlyproperties.json index 600b38ebbb..016b785340 100644 --- a/src/cfnlint/data/schemas/patches/providers/all/aws_elasticloadbalancing_loadbalancer/readonlyproperties.json +++ b/src/cfnlint/data/schemas/patches/providers/all/aws_elasticloadbalancing_loadbalancer/readonlyproperties.json @@ -37,7 +37,7 @@ "value": { "properties": { "GroupName": { - "format": "AWS::EC2::SecurityGroup.GroupName", + "format": "AWS::EC2::SecurityGroup.Name", "type": "string" }, "OwnerAlias": { diff --git a/src/cfnlint/data/schemas/providers/af_south_1/aws-apigatewayv2-vpclink.json b/src/cfnlint/data/schemas/providers/af_south_1/aws-apigatewayv2-vpclink.json index 6122cf0cee..d29422996a 100644 --- a/src/cfnlint/data/schemas/providers/af_south_1/aws-apigatewayv2-vpclink.json +++ b/src/cfnlint/data/schemas/providers/af_south_1/aws-apigatewayv2-vpclink.json @@ -17,7 +17,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/af_south_1/aws-ec2-clientvpnendpoint.json b/src/cfnlint/data/schemas/providers/af_south_1/aws-ec2-clientvpnendpoint.json index 456d6c66ca..f6410e35e5 100644 --- a/src/cfnlint/data/schemas/providers/af_south_1/aws-ec2-clientvpnendpoint.json +++ b/src/cfnlint/data/schemas/providers/af_south_1/aws-ec2-clientvpnendpoint.json @@ -191,7 +191,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/af_south_1/aws-m2-environment.json b/src/cfnlint/data/schemas/providers/af_south_1/aws-m2-environment.json index 65f6cde82f..eefe1e876a 100644 --- a/src/cfnlint/data/schemas/providers/af_south_1/aws-m2-environment.json +++ b/src/cfnlint/data/schemas/providers/af_south_1/aws-m2-environment.json @@ -170,7 +170,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^\\S{1,50}$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/af_south_1/aws-opsworks-layer.json b/src/cfnlint/data/schemas/providers/af_south_1/aws-opsworks-layer.json index 9c1034b219..6108ba70de 100644 --- a/src/cfnlint/data/schemas/providers/af_south_1/aws-opsworks-layer.json +++ b/src/cfnlint/data/schemas/providers/af_south_1/aws-opsworks-layer.json @@ -191,7 +191,9 @@ "$ref": "#/definitions/Recipes" }, "CustomSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_east_1/aws-ec2-clientvpnendpoint.json b/src/cfnlint/data/schemas/providers/ap_east_1/aws-ec2-clientvpnendpoint.json index 456d6c66ca..f6410e35e5 100644 --- a/src/cfnlint/data/schemas/providers/ap_east_1/aws-ec2-clientvpnendpoint.json +++ b/src/cfnlint/data/schemas/providers/ap_east_1/aws-ec2-clientvpnendpoint.json @@ -191,7 +191,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_east_1/aws-memorydb-cluster.json b/src/cfnlint/data/schemas/providers/ap_east_1/aws-memorydb-cluster.json index cba3a3f129..b6bd694646 100644 --- a/src/cfnlint/data/schemas/providers/ap_east_1/aws-memorydb-cluster.json +++ b/src/cfnlint/data/schemas/providers/ap_east_1/aws-memorydb-cluster.json @@ -118,7 +118,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_east_1/aws-sagemaker-domain.json b/src/cfnlint/data/schemas/providers/ap_east_1/aws-sagemaker-domain.json index 94720f00bb..69e42e460e 100644 --- a/src/cfnlint/data/schemas/providers/ap_east_1/aws-sagemaker-domain.json +++ b/src/cfnlint/data/schemas/providers/ap_east_1/aws-sagemaker-domain.json @@ -180,7 +180,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -254,7 +254,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -738,7 +738,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/ap_east_1/aws-sagemaker-userprofile.json b/src/cfnlint/data/schemas/providers/ap_east_1/aws-sagemaker-userprofile.json index 2d4d1a2f88..a21ea9e798 100644 --- a/src/cfnlint/data/schemas/providers/ap_east_1/aws-sagemaker-userprofile.json +++ b/src/cfnlint/data/schemas/providers/ap_east_1/aws-sagemaker-userprofile.json @@ -571,7 +571,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-pcs-cluster.json b/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-pcs-cluster.json index bd9b718b7d..0eb3ff4219 100644 --- a/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-pcs-cluster.json +++ b/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-pcs-cluster.json @@ -64,6 +64,7 @@ "type": "object" }, "SecurityGroupId": { + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "sg-\\w{8,17}", "type": "string" }, @@ -139,6 +140,7 @@ "additionalProperties": false, "properties": { "SecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { "$ref": "#/definitions/SecurityGroupId" diff --git a/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-sagemaker-domain.json b/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-sagemaker-domain.json index 94720f00bb..69e42e460e 100644 --- a/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-sagemaker-domain.json +++ b/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-sagemaker-domain.json @@ -180,7 +180,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -254,7 +254,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -738,7 +738,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-sagemaker-userprofile.json b/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-sagemaker-userprofile.json index 2d4d1a2f88..a21ea9e798 100644 --- a/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-sagemaker-userprofile.json +++ b/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-sagemaker-userprofile.json @@ -571,7 +571,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-timestream-influxdbinstance.json b/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-timestream-influxdbinstance.json index 3cd225dc53..bfd94ca75f 100644 --- a/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-timestream-influxdbinstance.json +++ b/src/cfnlint/data/schemas/providers/ap_northeast_1/aws-timestream-influxdbinstance.json @@ -191,8 +191,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/ap_northeast_2/aws-cloudformation-typeactivation.json b/src/cfnlint/data/schemas/providers/ap_northeast_2/aws-cloudformation-typeactivation.json index 730262bfac..ff8c82293d 100644 --- a/src/cfnlint/data/schemas/providers/ap_northeast_2/aws-cloudformation-typeactivation.json +++ b/src/cfnlint/data/schemas/providers/ap_northeast_2/aws-cloudformation-typeactivation.json @@ -14,6 +14,7 @@ "additionalProperties": false, "properties": { "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "^[\\.\\-_/#A-Za-z0-9]+$", diff --git a/src/cfnlint/data/schemas/providers/ap_northeast_2/aws-emrserverless-application.json b/src/cfnlint/data/schemas/providers/ap_northeast_2/aws-emrserverless-application.json new file mode 100644 index 0000000000..1d2c5c86ed --- /dev/null +++ b/src/cfnlint/data/schemas/providers/ap_northeast_2/aws-emrserverless-application.json @@ -0,0 +1,556 @@ +{ + "additionalProperties": false, + "conditionalCreateOnlyProperties": [ + "/properties/Architecture", + "/properties/ReleaseLabel", + "/properties/WorkerTypeSpecifications", + "/properties/MaximumCapacity", + "/properties/InitialCapacity", + "/properties/AutoStartConfiguration", + "/properties/AutoStopConfiguration", + "/properties/NetworkConfiguration", + "/properties/ImageConfiguration", + "/properties/MonitoringConfiguration", + "/properties/RuntimeConfiguration", + "/properties/InteractiveConfiguration", + "/properties/SchedulerConfiguration" + ], + "createOnlyProperties": [ + "/properties/Name", + "/properties/Type" + ], + "definitions": { + "Architecture": { + "enum": [ + "ARM64", + "X86_64" + ], + "type": "string" + }, + "AutoStartConfiguration": { + "additionalProperties": false, + "properties": { + "Enabled": { + "default": true, + "type": "boolean" + } + }, + "required": [], + "type": "object" + }, + "AutoStopConfiguration": { + "additionalProperties": false, + "properties": { + "Enabled": { + "default": true, + "type": "boolean" + }, + "IdleTimeoutMinutes": { + "type": "integer" + } + }, + "required": [], + "type": "object" + }, + "Classification": { + "maxLength": 1024, + "minLength": 1, + "pattern": ".*\\S.*", + "type": "string" + }, + "CloudWatchLoggingConfiguration": { + "additionalProperties": false, + "properties": { + "Enabled": { + "default": false, + "type": "boolean" + }, + "EncryptionKeyArn": { + "$ref": "#/definitions/EncryptionKeyArn" + }, + "LogGroupName": { + "$ref": "#/definitions/LogGroupName" + }, + "LogStreamNamePrefix": { + "$ref": "#/definitions/LogStreamNamePrefix" + }, + "LogTypeMap": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/LogTypeMapKeyValuePair" + }, + "type": "array", + "uniqueItems": true + } + } + }, + "ConfigurationList": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/ConfigurationObject" + }, + "type": "array", + "uniqueItems": true + }, + "ConfigurationObject": { + "additionalProperties": false, + "properties": { + "Classification": { + "$ref": "#/definitions/Classification" + }, + "Configurations": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/ConfigurationObject" + }, + "type": "array", + "uniqueItems": true + }, + "Properties": { + "additionalProperties": false, + "patternProperties": { + "^[a-zA-Z]+[-a-zA-Z0-9_.]*$": { + "$ref": "#/definitions/SensitivePropertiesMap" + } + }, + "type": "object" + } + }, + "required": [ + "Classification" + ], + "type": "object" + }, + "CpuSize": { + "maxLength": 15, + "minLength": 1, + "pattern": "^[1-9][0-9]*(\\s)?(vCPU|vcpu|VCPU)?$", + "type": "string" + }, + "DiskSize": { + "maxLength": 15, + "minLength": 1, + "pattern": "^[1-9][0-9]*(\\s)?(GB|gb|gB|Gb)$", + "type": "string" + }, + "DiskType": { + "pattern": "^(SHUFFLE_OPTIMIZED|[Ss]huffle_[Oo]ptimized|STANDARD|[Ss]tandard)$", + "type": "string" + }, + "EncryptionKeyArn": { + "maxLength": 2048, + "minLength": 20, + "pattern": "^arn:(aws[a-zA-Z0-9-]*):kms:[a-zA-Z0-9\\-]*:(\\d{12})?:key\\/[a-zA-Z0-9-]+$", + "type": "string" + }, + "ImageConfigurationInput": { + "additionalProperties": false, + "properties": { + "ImageUri": { + "maxLength": 1024, + "minLength": 1, + "pattern": "^([a-z0-9]+[a-z0-9-.]*)\\/((?:[a-z0-9]+(?:[._-][a-z0-9]+)*\\/)*[a-z0-9]+(?:[._-][a-z0-9]+)*)(?:\\:([a-zA-Z0-9_][a-zA-Z0-9-._]{0,299})|@(sha256:[0-9a-f]{64}))$", + "type": "string" + } + }, + "type": "object" + }, + "InitialCapacityConfig": { + "additionalProperties": false, + "properties": { + "WorkerConfiguration": { + "$ref": "#/definitions/WorkerConfiguration" + }, + "WorkerCount": { + "format": "int64", + "maximum": 1000000, + "minimum": 1, + "type": "integer" + } + }, + "required": [ + "WorkerCount", + "WorkerConfiguration" + ], + "type": "object" + }, + "InitialCapacityConfigKeyValuePair": { + "additionalProperties": false, + "properties": { + "Key": { + "maxLength": 50, + "minLength": 1, + "pattern": "^[a-zA-Z]+[-_]*[a-zA-Z]+$", + "type": "string" + }, + "Value": { + "$ref": "#/definitions/InitialCapacityConfig" + } + }, + "required": [ + "Key", + "Value" + ], + "type": "object" + }, + "InitialCapacityConfigMap": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/InitialCapacityConfigKeyValuePair" + }, + "type": "array", + "uniqueItems": true + }, + "InteractiveConfiguration": { + "additionalProperties": false, + "properties": { + "LivyEndpointEnabled": { + "default": false, + "type": "boolean" + }, + "StudioEnabled": { + "default": false, + "type": "boolean" + } + }, + "type": "object" + }, + "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", + "maxLength": 512, + "minLength": 1, + "pattern": "^[\\.\\-_/#A-Za-z0-9]+$", + "type": "string" + }, + "LogStreamNamePrefix": { + "maxLength": 512, + "minLength": 1, + "pattern": "^[^:*]*$", + "type": "string" + }, + "LogTypeList": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/LogTypeString" + }, + "maxItems": 5, + "minItems": 1, + "type": "array", + "uniqueItems": true + }, + "LogTypeMapKeyValuePair": { + "additionalProperties": false, + "properties": { + "Key": { + "$ref": "#/definitions/WorkerTypeString" + }, + "Value": { + "$ref": "#/definitions/LogTypeList" + } + }, + "required": [ + "Key", + "Value" + ], + "type": "object" + }, + "LogTypeString": { + "maxLength": 50, + "minLength": 1, + "pattern": "^[a-zA-Z]+[-_]*[a-zA-Z]+$", + "type": "string" + }, + "ManagedPersistenceMonitoringConfiguration": { + "additionalProperties": false, + "properties": { + "Enabled": { + "default": true, + "type": "boolean" + }, + "EncryptionKeyArn": { + "$ref": "#/definitions/EncryptionKeyArn" + } + } + }, + "MaximumAllowedResources": { + "additionalProperties": false, + "properties": { + "Cpu": { + "$ref": "#/definitions/CpuSize" + }, + "Disk": { + "$ref": "#/definitions/DiskSize" + }, + "Memory": { + "$ref": "#/definitions/MemorySize" + } + }, + "required": [ + "Cpu", + "Memory" + ], + "type": "object" + }, + "MemorySize": { + "maxLength": 15, + "minLength": 1, + "pattern": "^[1-9][0-9]*(\\s)?(GB|gb|gB|Gb)?$", + "type": "string" + }, + "MonitoringConfiguration": { + "additionalProperties": false, + "properties": { + "CloudWatchLoggingConfiguration": { + "$ref": "#/definitions/CloudWatchLoggingConfiguration" + }, + "ManagedPersistenceMonitoringConfiguration": { + "$ref": "#/definitions/ManagedPersistenceMonitoringConfiguration" + }, + "S3MonitoringConfiguration": { + "$ref": "#/definitions/S3MonitoringConfiguration" + } + }, + "type": "object" + }, + "NetworkConfiguration": { + "additionalProperties": false, + "properties": { + "SecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", + "insertionOrder": false, + "items": { + "$ref": "#/definitions/SecurityGroupId" + }, + "maxItems": 5, + "minItems": 1, + "type": "array", + "uniqueItems": true + }, + "SubnetIds": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/SubnetId" + }, + "maxItems": 16, + "minItems": 1, + "type": "array", + "uniqueItems": true + } + }, + "required": [], + "type": "object" + }, + "S3MonitoringConfiguration": { + "additionalProperties": false, + "properties": { + "EncryptionKeyArn": { + "$ref": "#/definitions/EncryptionKeyArn" + }, + "LogUri": { + "$ref": "#/definitions/UriString" + } + } + }, + "SchedulerConfiguration": { + "additionalProperties": false, + "properties": { + "MaxConcurrentRuns": { + "type": "integer" + }, + "QueueTimeoutMinutes": { + "type": "integer" + } + }, + "type": "object" + }, + "SecurityGroupId": { + "format": "AWS::EC2::SecurityGroup.Id", + "maxLength": 32, + "minLength": 1, + "pattern": "[-0-9a-zA-Z]+.*", + "type": "string" + }, + "SensitivePropertiesKeyValuePair": { + "maxLength": 1024, + "minLength": 1, + "pattern": ".*\\S.*", + "type": "string" + }, + "SensitivePropertiesMap": { + "maxLength": 1024, + "minLength": 1, + "pattern": ".*\\S.*", + "type": "string" + }, + "SubnetId": { + "maxLength": 32, + "minLength": 1, + "pattern": "[-0-9a-zA-Z]+.*", + "type": "string" + }, + "Tag": { + "additionalProperties": false, + "properties": { + "Key": { + "maxLength": 128, + "minLength": 1, + "pattern": "^[A-Za-z0-9 /_.:=+@-]+$", + "type": "string" + }, + "Value": { + "maxLength": 256, + "minLength": 0, + "pattern": "^[A-Za-z0-9 /_.:=+@-]*$", + "type": "string" + } + }, + "required": [ + "Key", + "Value" + ], + "type": "object" + }, + "UriString": { + "maxLength": 10280, + "minLength": 1, + "pattern": "[\\u0020-\\uD7FF\\uE000-\\uFFFD\\uD800\\uDBFF-\\uDC00\\uDFFF\\r\\n\\t]*", + "type": "string" + }, + "WorkerConfiguration": { + "additionalProperties": false, + "properties": { + "Cpu": { + "$ref": "#/definitions/CpuSize" + }, + "Disk": { + "$ref": "#/definitions/DiskSize" + }, + "DiskType": { + "$ref": "#/definitions/DiskType" + }, + "Memory": { + "$ref": "#/definitions/MemorySize" + } + }, + "required": [ + "Cpu", + "Memory" + ], + "type": "object" + }, + "WorkerTypeSpecificationInput": { + "additionalProperties": false, + "properties": { + "ImageConfiguration": { + "$ref": "#/definitions/ImageConfigurationInput" + } + }, + "type": "object" + }, + "WorkerTypeSpecificationInputMap": { + "additionalProperties": false, + "patternProperties": { + "^[a-zA-Z]+[-_]*[a-zA-Z]+$": { + "$ref": "#/definitions/WorkerTypeSpecificationInput" + } + }, + "type": "object" + }, + "WorkerTypeString": { + "maxLength": 50, + "minLength": 1, + "pattern": "^[a-zA-Z]+[-_]*[a-zA-Z]+$", + "type": "string" + } + }, + "primaryIdentifier": [ + "/properties/ApplicationId" + ], + "properties": { + "ApplicationId": { + "maxLength": 64, + "minLength": 1, + "type": "string" + }, + "Architecture": { + "$ref": "#/definitions/Architecture" + }, + "Arn": { + "pattern": "^arn:(aws[a-zA-Z0-9-]*):emr-serverless:.+:(\\d{12}):\\/applications\\/[0-9a-zA-Z]+$", + "type": "string" + }, + "AutoStartConfiguration": { + "$ref": "#/definitions/AutoStartConfiguration" + }, + "AutoStopConfiguration": { + "$ref": "#/definitions/AutoStopConfiguration" + }, + "ImageConfiguration": { + "$ref": "#/definitions/ImageConfigurationInput" + }, + "InitialCapacity": { + "$ref": "#/definitions/InitialCapacityConfigMap" + }, + "InteractiveConfiguration": { + "$ref": "#/definitions/InteractiveConfiguration" + }, + "MaximumCapacity": { + "$ref": "#/definitions/MaximumAllowedResources" + }, + "MonitoringConfiguration": { + "$ref": "#/definitions/MonitoringConfiguration" + }, + "Name": { + "maxLength": 64, + "minLength": 1, + "pattern": "^[A-Za-z0-9._\\/#-]+$", + "type": "string" + }, + "NetworkConfiguration": { + "$ref": "#/definitions/NetworkConfiguration" + }, + "ReleaseLabel": { + "maxLength": 64, + "minLength": 1, + "pattern": "^[A-Za-z0-9._/-]+$", + "type": "string" + }, + "RuntimeConfiguration": { + "$ref": "#/definitions/ConfigurationList" + }, + "SchedulerConfiguration": { + "$ref": "#/definitions/SchedulerConfiguration" + }, + "Tags": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/Tag" + }, + "type": "array", + "uniqueItems": true + }, + "Type": { + "type": "string" + }, + "WorkerTypeSpecifications": { + "$ref": "#/definitions/WorkerTypeSpecificationInputMap" + } + }, + "readOnlyProperties": [ + "/properties/Arn", + "/properties/ApplicationId" + ], + "required": [ + "ReleaseLabel", + "Type" + ], + "sourceUrl": "https://github.com/aws-cloudformation/aws-cloudformation-rpdk.git", + "tagging": { + "cloudFormationSystemTags": false, + "tagOnCreate": true, + "tagProperty": "/properties/Tags", + "tagUpdatable": true, + "taggable": true + }, + "typeName": "AWS::EMRServerless::Application" +} diff --git a/src/cfnlint/data/schemas/providers/ap_northeast_2/aws-m2-environment.json b/src/cfnlint/data/schemas/providers/ap_northeast_2/aws-m2-environment.json index 65f6cde82f..eefe1e876a 100644 --- a/src/cfnlint/data/schemas/providers/ap_northeast_2/aws-m2-environment.json +++ b/src/cfnlint/data/schemas/providers/ap_northeast_2/aws-m2-environment.json @@ -170,7 +170,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^\\S{1,50}$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-apigatewayv2-vpclink.json b/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-apigatewayv2-vpclink.json index 6122cf0cee..d29422996a 100644 --- a/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-apigatewayv2-vpclink.json +++ b/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-apigatewayv2-vpclink.json @@ -17,7 +17,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-ec2-clientvpnendpoint.json b/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-ec2-clientvpnendpoint.json index 456d6c66ca..f6410e35e5 100644 --- a/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-ec2-clientvpnendpoint.json +++ b/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-ec2-clientvpnendpoint.json @@ -191,7 +191,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-fsx-filesystem.json b/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-fsx-filesystem.json index f63c43e724..f6dacdc4b5 100644 --- a/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-fsx-filesystem.json +++ b/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-fsx-filesystem.json @@ -418,7 +418,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-m2-environment.json b/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-m2-environment.json index 65f6cde82f..eefe1e876a 100644 --- a/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-m2-environment.json +++ b/src/cfnlint/data/schemas/providers/ap_northeast_3/aws-m2-environment.json @@ -170,7 +170,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^\\S{1,50}$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/ap_south_1/aws-codebuild-fleet.json b/src/cfnlint/data/schemas/providers/ap_south_1/aws-codebuild-fleet.json index 85c9bd3cbe..05ad47e89e 100644 --- a/src/cfnlint/data/schemas/providers/ap_south_1/aws-codebuild-fleet.json +++ b/src/cfnlint/data/schemas/providers/ap_south_1/aws-codebuild-fleet.json @@ -136,7 +136,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/ap_south_1/aws-timestream-influxdbinstance.json b/src/cfnlint/data/schemas/providers/ap_south_1/aws-timestream-influxdbinstance.json index 3cd225dc53..bfd94ca75f 100644 --- a/src/cfnlint/data/schemas/providers/ap_south_1/aws-timestream-influxdbinstance.json +++ b/src/cfnlint/data/schemas/providers/ap_south_1/aws-timestream-influxdbinstance.json @@ -191,8 +191,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/ap_south_2/aws-ec2-clientvpnendpoint.json b/src/cfnlint/data/schemas/providers/ap_south_2/aws-ec2-clientvpnendpoint.json index 456d6c66ca..f6410e35e5 100644 --- a/src/cfnlint/data/schemas/providers/ap_south_2/aws-ec2-clientvpnendpoint.json +++ b/src/cfnlint/data/schemas/providers/ap_south_2/aws-ec2-clientvpnendpoint.json @@ -191,7 +191,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_south_2/aws-ec2-spotfleet.json b/src/cfnlint/data/schemas/providers/ap_south_2/aws-ec2-spotfleet.json index e88a9d9272..7a7dd681df 100644 --- a/src/cfnlint/data/schemas/providers/ap_south_2/aws-ec2-spotfleet.json +++ b/src/cfnlint/data/schemas/providers/ap_south_2/aws-ec2-spotfleet.json @@ -109,7 +109,7 @@ }, "GroupIdentifier": { "additionalProperties": false, - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "properties": { "GroupId": { "type": "string" diff --git a/src/cfnlint/data/schemas/providers/ap_south_2/aws-fsx-filesystem.json b/src/cfnlint/data/schemas/providers/ap_south_2/aws-fsx-filesystem.json index f63c43e724..f6dacdc4b5 100644 --- a/src/cfnlint/data/schemas/providers/ap_south_2/aws-fsx-filesystem.json +++ b/src/cfnlint/data/schemas/providers/ap_south_2/aws-fsx-filesystem.json @@ -418,7 +418,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_south_2/aws-opsworks-layer.json b/src/cfnlint/data/schemas/providers/ap_south_2/aws-opsworks-layer.json index 9c1034b219..6108ba70de 100644 --- a/src/cfnlint/data/schemas/providers/ap_south_2/aws-opsworks-layer.json +++ b/src/cfnlint/data/schemas/providers/ap_south_2/aws-opsworks-layer.json @@ -191,7 +191,9 @@ "$ref": "#/definitions/Recipes" }, "CustomSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_1/aws-pcs-cluster.json b/src/cfnlint/data/schemas/providers/ap_southeast_1/aws-pcs-cluster.json index bd9b718b7d..0eb3ff4219 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_1/aws-pcs-cluster.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_1/aws-pcs-cluster.json @@ -64,6 +64,7 @@ "type": "object" }, "SecurityGroupId": { + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "sg-\\w{8,17}", "type": "string" }, @@ -139,6 +140,7 @@ "additionalProperties": false, "properties": { "SecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { "$ref": "#/definitions/SecurityGroupId" diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_2/aws-codebuild-fleet.json b/src/cfnlint/data/schemas/providers/ap_southeast_2/aws-codebuild-fleet.json index 85c9bd3cbe..05ad47e89e 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_2/aws-codebuild-fleet.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_2/aws-codebuild-fleet.json @@ -136,7 +136,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_2/aws-pcs-computenodegroup.json b/src/cfnlint/data/schemas/providers/ap_southeast_2/aws-pcs-computenodegroup.json index c87f471efd..18a817ec0f 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_2/aws-pcs-computenodegroup.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_2/aws-pcs-computenodegroup.json @@ -52,6 +52,7 @@ ], "properties": { "AmiId": { + "format": "AWS::EC2::Image.Id", "pattern": "^ami-[a-z0-9]+$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_2/aws-timestream-influxdbinstance.json b/src/cfnlint/data/schemas/providers/ap_southeast_2/aws-timestream-influxdbinstance.json index 3cd225dc53..bfd94ca75f 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_2/aws-timestream-influxdbinstance.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_2/aws-timestream-influxdbinstance.json @@ -191,8 +191,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_3/aws-ec2-clientvpnendpoint.json b/src/cfnlint/data/schemas/providers/ap_southeast_3/aws-ec2-clientvpnendpoint.json index 456d6c66ca..f6410e35e5 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_3/aws-ec2-clientvpnendpoint.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_3/aws-ec2-clientvpnendpoint.json @@ -191,7 +191,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_3/aws-opsworks-layer.json b/src/cfnlint/data/schemas/providers/ap_southeast_3/aws-opsworks-layer.json index 9c1034b219..6108ba70de 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_3/aws-opsworks-layer.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_3/aws-opsworks-layer.json @@ -191,7 +191,9 @@ "$ref": "#/definitions/Recipes" }, "CustomSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_3/aws-timestream-influxdbinstance.json b/src/cfnlint/data/schemas/providers/ap_southeast_3/aws-timestream-influxdbinstance.json index 3cd225dc53..bfd94ca75f 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_3/aws-timestream-influxdbinstance.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_3/aws-timestream-influxdbinstance.json @@ -191,8 +191,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-autoscaling-launchconfiguration.json b/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-autoscaling-launchconfiguration.json index 944f5608ad..fd40ebb2b7 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-autoscaling-launchconfiguration.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-autoscaling-launchconfiguration.json @@ -175,7 +175,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-ec2-clientvpnendpoint.json b/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-ec2-clientvpnendpoint.json index 456d6c66ca..f6410e35e5 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-ec2-clientvpnendpoint.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-ec2-clientvpnendpoint.json @@ -191,7 +191,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-ec2-spotfleet.json b/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-ec2-spotfleet.json index e88a9d9272..7a7dd681df 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-ec2-spotfleet.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-ec2-spotfleet.json @@ -109,7 +109,7 @@ }, "GroupIdentifier": { "additionalProperties": false, - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "properties": { "GroupId": { "type": "string" diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-lambda-function.json b/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-lambda-function.json index 766fb09230..f51567aa84 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-lambda-function.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-lambda-function.json @@ -269,7 +269,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-opsworks-layer.json b/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-opsworks-layer.json index 9c1034b219..6108ba70de 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-opsworks-layer.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_4/aws-opsworks-layer.json @@ -191,7 +191,9 @@ "$ref": "#/definitions/Recipes" }, "CustomSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_5/aws-autoscaling-launchconfiguration.json b/src/cfnlint/data/schemas/providers/ap_southeast_5/aws-autoscaling-launchconfiguration.json index 944f5608ad..fd40ebb2b7 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_5/aws-autoscaling-launchconfiguration.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_5/aws-autoscaling-launchconfiguration.json @@ -175,7 +175,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_5/aws-opsworks-layer.json b/src/cfnlint/data/schemas/providers/ap_southeast_5/aws-opsworks-layer.json index 9c1034b219..6108ba70de 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_5/aws-opsworks-layer.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_5/aws-opsworks-layer.json @@ -191,7 +191,9 @@ "$ref": "#/definitions/Recipes" }, "CustomSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_7/aws-autoscaling-launchconfiguration.json b/src/cfnlint/data/schemas/providers/ap_southeast_7/aws-autoscaling-launchconfiguration.json index 944f5608ad..fd40ebb2b7 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_7/aws-autoscaling-launchconfiguration.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_7/aws-autoscaling-launchconfiguration.json @@ -175,7 +175,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_7/aws-kinesisfirehose-deliverystream.json b/src/cfnlint/data/schemas/providers/ap_southeast_7/aws-kinesisfirehose-deliverystream.json index 632e0c4b67..bcd6030d1b 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_7/aws-kinesisfirehose-deliverystream.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_7/aws-kinesisfirehose-deliverystream.json @@ -28,6 +28,7 @@ "type": "boolean" }, "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "pattern": "[\\.\\-_/#A-Za-z0-9]*", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/ap_southeast_7/aws-opsworks-layer.json b/src/cfnlint/data/schemas/providers/ap_southeast_7/aws-opsworks-layer.json index 9c1034b219..6108ba70de 100644 --- a/src/cfnlint/data/schemas/providers/ap_southeast_7/aws-opsworks-layer.json +++ b/src/cfnlint/data/schemas/providers/ap_southeast_7/aws-opsworks-layer.json @@ -191,7 +191,9 @@ "$ref": "#/definitions/Recipes" }, "CustomSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ca_central_1/aws-appstream-imagebuilder.json b/src/cfnlint/data/schemas/providers/ca_central_1/aws-appstream-imagebuilder.json index 1f77bfb4b1..41919ec829 100644 --- a/src/cfnlint/data/schemas/providers/ca_central_1/aws-appstream-imagebuilder.json +++ b/src/cfnlint/data/schemas/providers/ca_central_1/aws-appstream-imagebuilder.json @@ -54,7 +54,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ca_central_1/aws-memorydb-cluster.json b/src/cfnlint/data/schemas/providers/ca_central_1/aws-memorydb-cluster.json index cba3a3f129..b6bd694646 100644 --- a/src/cfnlint/data/schemas/providers/ca_central_1/aws-memorydb-cluster.json +++ b/src/cfnlint/data/schemas/providers/ca_central_1/aws-memorydb-cluster.json @@ -118,7 +118,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ca_central_1/aws-timestream-influxdbinstance.json b/src/cfnlint/data/schemas/providers/ca_central_1/aws-timestream-influxdbinstance.json index 3cd225dc53..bfd94ca75f 100644 --- a/src/cfnlint/data/schemas/providers/ca_central_1/aws-timestream-influxdbinstance.json +++ b/src/cfnlint/data/schemas/providers/ca_central_1/aws-timestream-influxdbinstance.json @@ -191,8 +191,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/ca_west_1/aws-autoscaling-launchconfiguration.json b/src/cfnlint/data/schemas/providers/ca_west_1/aws-autoscaling-launchconfiguration.json index 944f5608ad..fd40ebb2b7 100644 --- a/src/cfnlint/data/schemas/providers/ca_west_1/aws-autoscaling-launchconfiguration.json +++ b/src/cfnlint/data/schemas/providers/ca_west_1/aws-autoscaling-launchconfiguration.json @@ -175,7 +175,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/ca_west_1/aws-opsworks-layer.json b/src/cfnlint/data/schemas/providers/ca_west_1/aws-opsworks-layer.json index 9c1034b219..6108ba70de 100644 --- a/src/cfnlint/data/schemas/providers/ca_west_1/aws-opsworks-layer.json +++ b/src/cfnlint/data/schemas/providers/ca_west_1/aws-opsworks-layer.json @@ -191,7 +191,9 @@ "$ref": "#/definitions/Recipes" }, "CustomSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/cn_north_1/aws-rds-dbcluster.json b/src/cfnlint/data/schemas/providers/cn_north_1/aws-rds-dbcluster.json index b13e6afc3d..6f4e0e1a17 100644 --- a/src/cfnlint/data/schemas/providers/cn_north_1/aws-rds-dbcluster.json +++ b/src/cfnlint/data/schemas/providers/cn_north_1/aws-rds-dbcluster.json @@ -349,7 +349,9 @@ "type": "boolean" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/cn_northwest_1/aws-appstream-fleet.json b/src/cfnlint/data/schemas/providers/cn_northwest_1/aws-appstream-fleet.json index 2d379bfa28..a58b19b86d 100644 --- a/src/cfnlint/data/schemas/providers/cn_northwest_1/aws-appstream-fleet.json +++ b/src/cfnlint/data/schemas/providers/cn_northwest_1/aws-appstream-fleet.json @@ -51,7 +51,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/cn_northwest_1/aws-appstream-imagebuilder.json b/src/cfnlint/data/schemas/providers/cn_northwest_1/aws-appstream-imagebuilder.json index 1f77bfb4b1..41919ec829 100644 --- a/src/cfnlint/data/schemas/providers/cn_northwest_1/aws-appstream-imagebuilder.json +++ b/src/cfnlint/data/schemas/providers/cn_northwest_1/aws-appstream-imagebuilder.json @@ -54,7 +54,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/cn_northwest_1/aws-fsx-filesystem.json b/src/cfnlint/data/schemas/providers/cn_northwest_1/aws-fsx-filesystem.json index 435c672a40..ce06b0b00b 100644 --- a/src/cfnlint/data/schemas/providers/cn_northwest_1/aws-fsx-filesystem.json +++ b/src/cfnlint/data/schemas/providers/cn_northwest_1/aws-fsx-filesystem.json @@ -400,7 +400,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_central_1/aws-pcs-cluster.json b/src/cfnlint/data/schemas/providers/eu_central_1/aws-pcs-cluster.json index bd9b718b7d..0eb3ff4219 100644 --- a/src/cfnlint/data/schemas/providers/eu_central_1/aws-pcs-cluster.json +++ b/src/cfnlint/data/schemas/providers/eu_central_1/aws-pcs-cluster.json @@ -64,6 +64,7 @@ "type": "object" }, "SecurityGroupId": { + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "sg-\\w{8,17}", "type": "string" }, @@ -139,6 +140,7 @@ "additionalProperties": false, "properties": { "SecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { "$ref": "#/definitions/SecurityGroupId" diff --git a/src/cfnlint/data/schemas/providers/eu_central_1/aws-timestream-influxdbinstance.json b/src/cfnlint/data/schemas/providers/eu_central_1/aws-timestream-influxdbinstance.json index 3cd225dc53..bfd94ca75f 100644 --- a/src/cfnlint/data/schemas/providers/eu_central_1/aws-timestream-influxdbinstance.json +++ b/src/cfnlint/data/schemas/providers/eu_central_1/aws-timestream-influxdbinstance.json @@ -191,8 +191,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/eu_central_2/aws-cloudformation-typeactivation.json b/src/cfnlint/data/schemas/providers/eu_central_2/aws-cloudformation-typeactivation.json index 730262bfac..ff8c82293d 100644 --- a/src/cfnlint/data/schemas/providers/eu_central_2/aws-cloudformation-typeactivation.json +++ b/src/cfnlint/data/schemas/providers/eu_central_2/aws-cloudformation-typeactivation.json @@ -14,6 +14,7 @@ "additionalProperties": false, "properties": { "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "^[\\.\\-_/#A-Za-z0-9]+$", diff --git a/src/cfnlint/data/schemas/providers/eu_central_2/aws-ec2-clientvpnendpoint.json b/src/cfnlint/data/schemas/providers/eu_central_2/aws-ec2-clientvpnendpoint.json index 456d6c66ca..f6410e35e5 100644 --- a/src/cfnlint/data/schemas/providers/eu_central_2/aws-ec2-clientvpnendpoint.json +++ b/src/cfnlint/data/schemas/providers/eu_central_2/aws-ec2-clientvpnendpoint.json @@ -191,7 +191,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_central_2/aws-fsx-filesystem.json b/src/cfnlint/data/schemas/providers/eu_central_2/aws-fsx-filesystem.json index f63c43e724..f6dacdc4b5 100644 --- a/src/cfnlint/data/schemas/providers/eu_central_2/aws-fsx-filesystem.json +++ b/src/cfnlint/data/schemas/providers/eu_central_2/aws-fsx-filesystem.json @@ -418,7 +418,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_central_2/aws-opsworks-layer.json b/src/cfnlint/data/schemas/providers/eu_central_2/aws-opsworks-layer.json index 9c1034b219..6108ba70de 100644 --- a/src/cfnlint/data/schemas/providers/eu_central_2/aws-opsworks-layer.json +++ b/src/cfnlint/data/schemas/providers/eu_central_2/aws-opsworks-layer.json @@ -191,7 +191,9 @@ "$ref": "#/definitions/Recipes" }, "CustomSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_north_1/aws-m2-environment.json b/src/cfnlint/data/schemas/providers/eu_north_1/aws-m2-environment.json index 65f6cde82f..eefe1e876a 100644 --- a/src/cfnlint/data/schemas/providers/eu_north_1/aws-m2-environment.json +++ b/src/cfnlint/data/schemas/providers/eu_north_1/aws-m2-environment.json @@ -170,7 +170,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^\\S{1,50}$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/eu_north_1/aws-memorydb-cluster.json b/src/cfnlint/data/schemas/providers/eu_north_1/aws-memorydb-cluster.json index cba3a3f129..b6bd694646 100644 --- a/src/cfnlint/data/schemas/providers/eu_north_1/aws-memorydb-cluster.json +++ b/src/cfnlint/data/schemas/providers/eu_north_1/aws-memorydb-cluster.json @@ -118,7 +118,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_north_1/aws-osis-pipeline.json b/src/cfnlint/data/schemas/providers/eu_north_1/aws-osis-pipeline.json index 74e53d8db5..fc300c116a 100644 --- a/src/cfnlint/data/schemas/providers/eu_north_1/aws-osis-pipeline.json +++ b/src/cfnlint/data/schemas/providers/eu_north_1/aws-osis-pipeline.json @@ -95,7 +95,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 20, "minLength": 11, "pattern": "sg-\\w{8}(\\w{9})?", diff --git a/src/cfnlint/data/schemas/providers/eu_north_1/aws-sagemaker-domain.json b/src/cfnlint/data/schemas/providers/eu_north_1/aws-sagemaker-domain.json index 94720f00bb..69e42e460e 100644 --- a/src/cfnlint/data/schemas/providers/eu_north_1/aws-sagemaker-domain.json +++ b/src/cfnlint/data/schemas/providers/eu_north_1/aws-sagemaker-domain.json @@ -180,7 +180,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -254,7 +254,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -738,7 +738,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/eu_north_1/aws-sagemaker-userprofile.json b/src/cfnlint/data/schemas/providers/eu_north_1/aws-sagemaker-userprofile.json index 2d4d1a2f88..a21ea9e798 100644 --- a/src/cfnlint/data/schemas/providers/eu_north_1/aws-sagemaker-userprofile.json +++ b/src/cfnlint/data/schemas/providers/eu_north_1/aws-sagemaker-userprofile.json @@ -571,7 +571,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/eu_south_1/aws-apigatewayv2-vpclink.json b/src/cfnlint/data/schemas/providers/eu_south_1/aws-apigatewayv2-vpclink.json index 6122cf0cee..d29422996a 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_1/aws-apigatewayv2-vpclink.json +++ b/src/cfnlint/data/schemas/providers/eu_south_1/aws-apigatewayv2-vpclink.json @@ -17,7 +17,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_south_1/aws-cloudformation-typeactivation.json b/src/cfnlint/data/schemas/providers/eu_south_1/aws-cloudformation-typeactivation.json index 730262bfac..ff8c82293d 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_1/aws-cloudformation-typeactivation.json +++ b/src/cfnlint/data/schemas/providers/eu_south_1/aws-cloudformation-typeactivation.json @@ -14,6 +14,7 @@ "additionalProperties": false, "properties": { "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "^[\\.\\-_/#A-Za-z0-9]+$", diff --git a/src/cfnlint/data/schemas/providers/eu_south_1/aws-ec2-clientvpnendpoint.json b/src/cfnlint/data/schemas/providers/eu_south_1/aws-ec2-clientvpnendpoint.json index 456d6c66ca..f6410e35e5 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_1/aws-ec2-clientvpnendpoint.json +++ b/src/cfnlint/data/schemas/providers/eu_south_1/aws-ec2-clientvpnendpoint.json @@ -191,7 +191,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_south_1/aws-emrserverless-application.json b/src/cfnlint/data/schemas/providers/eu_south_1/aws-emrserverless-application.json new file mode 100644 index 0000000000..1d2c5c86ed --- /dev/null +++ b/src/cfnlint/data/schemas/providers/eu_south_1/aws-emrserverless-application.json @@ -0,0 +1,556 @@ +{ + "additionalProperties": false, + "conditionalCreateOnlyProperties": [ + "/properties/Architecture", + "/properties/ReleaseLabel", + "/properties/WorkerTypeSpecifications", + "/properties/MaximumCapacity", + "/properties/InitialCapacity", + "/properties/AutoStartConfiguration", + "/properties/AutoStopConfiguration", + "/properties/NetworkConfiguration", + "/properties/ImageConfiguration", + "/properties/MonitoringConfiguration", + "/properties/RuntimeConfiguration", + "/properties/InteractiveConfiguration", + "/properties/SchedulerConfiguration" + ], + "createOnlyProperties": [ + "/properties/Name", + "/properties/Type" + ], + "definitions": { + "Architecture": { + "enum": [ + "ARM64", + "X86_64" + ], + "type": "string" + }, + "AutoStartConfiguration": { + "additionalProperties": false, + "properties": { + "Enabled": { + "default": true, + "type": "boolean" + } + }, + "required": [], + "type": "object" + }, + "AutoStopConfiguration": { + "additionalProperties": false, + "properties": { + "Enabled": { + "default": true, + "type": "boolean" + }, + "IdleTimeoutMinutes": { + "type": "integer" + } + }, + "required": [], + "type": "object" + }, + "Classification": { + "maxLength": 1024, + "minLength": 1, + "pattern": ".*\\S.*", + "type": "string" + }, + "CloudWatchLoggingConfiguration": { + "additionalProperties": false, + "properties": { + "Enabled": { + "default": false, + "type": "boolean" + }, + "EncryptionKeyArn": { + "$ref": "#/definitions/EncryptionKeyArn" + }, + "LogGroupName": { + "$ref": "#/definitions/LogGroupName" + }, + "LogStreamNamePrefix": { + "$ref": "#/definitions/LogStreamNamePrefix" + }, + "LogTypeMap": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/LogTypeMapKeyValuePair" + }, + "type": "array", + "uniqueItems": true + } + } + }, + "ConfigurationList": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/ConfigurationObject" + }, + "type": "array", + "uniqueItems": true + }, + "ConfigurationObject": { + "additionalProperties": false, + "properties": { + "Classification": { + "$ref": "#/definitions/Classification" + }, + "Configurations": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/ConfigurationObject" + }, + "type": "array", + "uniqueItems": true + }, + "Properties": { + "additionalProperties": false, + "patternProperties": { + "^[a-zA-Z]+[-a-zA-Z0-9_.]*$": { + "$ref": "#/definitions/SensitivePropertiesMap" + } + }, + "type": "object" + } + }, + "required": [ + "Classification" + ], + "type": "object" + }, + "CpuSize": { + "maxLength": 15, + "minLength": 1, + "pattern": "^[1-9][0-9]*(\\s)?(vCPU|vcpu|VCPU)?$", + "type": "string" + }, + "DiskSize": { + "maxLength": 15, + "minLength": 1, + "pattern": "^[1-9][0-9]*(\\s)?(GB|gb|gB|Gb)$", + "type": "string" + }, + "DiskType": { + "pattern": "^(SHUFFLE_OPTIMIZED|[Ss]huffle_[Oo]ptimized|STANDARD|[Ss]tandard)$", + "type": "string" + }, + "EncryptionKeyArn": { + "maxLength": 2048, + "minLength": 20, + "pattern": "^arn:(aws[a-zA-Z0-9-]*):kms:[a-zA-Z0-9\\-]*:(\\d{12})?:key\\/[a-zA-Z0-9-]+$", + "type": "string" + }, + "ImageConfigurationInput": { + "additionalProperties": false, + "properties": { + "ImageUri": { + "maxLength": 1024, + "minLength": 1, + "pattern": "^([a-z0-9]+[a-z0-9-.]*)\\/((?:[a-z0-9]+(?:[._-][a-z0-9]+)*\\/)*[a-z0-9]+(?:[._-][a-z0-9]+)*)(?:\\:([a-zA-Z0-9_][a-zA-Z0-9-._]{0,299})|@(sha256:[0-9a-f]{64}))$", + "type": "string" + } + }, + "type": "object" + }, + "InitialCapacityConfig": { + "additionalProperties": false, + "properties": { + "WorkerConfiguration": { + "$ref": "#/definitions/WorkerConfiguration" + }, + "WorkerCount": { + "format": "int64", + "maximum": 1000000, + "minimum": 1, + "type": "integer" + } + }, + "required": [ + "WorkerCount", + "WorkerConfiguration" + ], + "type": "object" + }, + "InitialCapacityConfigKeyValuePair": { + "additionalProperties": false, + "properties": { + "Key": { + "maxLength": 50, + "minLength": 1, + "pattern": "^[a-zA-Z]+[-_]*[a-zA-Z]+$", + "type": "string" + }, + "Value": { + "$ref": "#/definitions/InitialCapacityConfig" + } + }, + "required": [ + "Key", + "Value" + ], + "type": "object" + }, + "InitialCapacityConfigMap": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/InitialCapacityConfigKeyValuePair" + }, + "type": "array", + "uniqueItems": true + }, + "InteractiveConfiguration": { + "additionalProperties": false, + "properties": { + "LivyEndpointEnabled": { + "default": false, + "type": "boolean" + }, + "StudioEnabled": { + "default": false, + "type": "boolean" + } + }, + "type": "object" + }, + "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", + "maxLength": 512, + "minLength": 1, + "pattern": "^[\\.\\-_/#A-Za-z0-9]+$", + "type": "string" + }, + "LogStreamNamePrefix": { + "maxLength": 512, + "minLength": 1, + "pattern": "^[^:*]*$", + "type": "string" + }, + "LogTypeList": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/LogTypeString" + }, + "maxItems": 5, + "minItems": 1, + "type": "array", + "uniqueItems": true + }, + "LogTypeMapKeyValuePair": { + "additionalProperties": false, + "properties": { + "Key": { + "$ref": "#/definitions/WorkerTypeString" + }, + "Value": { + "$ref": "#/definitions/LogTypeList" + } + }, + "required": [ + "Key", + "Value" + ], + "type": "object" + }, + "LogTypeString": { + "maxLength": 50, + "minLength": 1, + "pattern": "^[a-zA-Z]+[-_]*[a-zA-Z]+$", + "type": "string" + }, + "ManagedPersistenceMonitoringConfiguration": { + "additionalProperties": false, + "properties": { + "Enabled": { + "default": true, + "type": "boolean" + }, + "EncryptionKeyArn": { + "$ref": "#/definitions/EncryptionKeyArn" + } + } + }, + "MaximumAllowedResources": { + "additionalProperties": false, + "properties": { + "Cpu": { + "$ref": "#/definitions/CpuSize" + }, + "Disk": { + "$ref": "#/definitions/DiskSize" + }, + "Memory": { + "$ref": "#/definitions/MemorySize" + } + }, + "required": [ + "Cpu", + "Memory" + ], + "type": "object" + }, + "MemorySize": { + "maxLength": 15, + "minLength": 1, + "pattern": "^[1-9][0-9]*(\\s)?(GB|gb|gB|Gb)?$", + "type": "string" + }, + "MonitoringConfiguration": { + "additionalProperties": false, + "properties": { + "CloudWatchLoggingConfiguration": { + "$ref": "#/definitions/CloudWatchLoggingConfiguration" + }, + "ManagedPersistenceMonitoringConfiguration": { + "$ref": "#/definitions/ManagedPersistenceMonitoringConfiguration" + }, + "S3MonitoringConfiguration": { + "$ref": "#/definitions/S3MonitoringConfiguration" + } + }, + "type": "object" + }, + "NetworkConfiguration": { + "additionalProperties": false, + "properties": { + "SecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", + "insertionOrder": false, + "items": { + "$ref": "#/definitions/SecurityGroupId" + }, + "maxItems": 5, + "minItems": 1, + "type": "array", + "uniqueItems": true + }, + "SubnetIds": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/SubnetId" + }, + "maxItems": 16, + "minItems": 1, + "type": "array", + "uniqueItems": true + } + }, + "required": [], + "type": "object" + }, + "S3MonitoringConfiguration": { + "additionalProperties": false, + "properties": { + "EncryptionKeyArn": { + "$ref": "#/definitions/EncryptionKeyArn" + }, + "LogUri": { + "$ref": "#/definitions/UriString" + } + } + }, + "SchedulerConfiguration": { + "additionalProperties": false, + "properties": { + "MaxConcurrentRuns": { + "type": "integer" + }, + "QueueTimeoutMinutes": { + "type": "integer" + } + }, + "type": "object" + }, + "SecurityGroupId": { + "format": "AWS::EC2::SecurityGroup.Id", + "maxLength": 32, + "minLength": 1, + "pattern": "[-0-9a-zA-Z]+.*", + "type": "string" + }, + "SensitivePropertiesKeyValuePair": { + "maxLength": 1024, + "minLength": 1, + "pattern": ".*\\S.*", + "type": "string" + }, + "SensitivePropertiesMap": { + "maxLength": 1024, + "minLength": 1, + "pattern": ".*\\S.*", + "type": "string" + }, + "SubnetId": { + "maxLength": 32, + "minLength": 1, + "pattern": "[-0-9a-zA-Z]+.*", + "type": "string" + }, + "Tag": { + "additionalProperties": false, + "properties": { + "Key": { + "maxLength": 128, + "minLength": 1, + "pattern": "^[A-Za-z0-9 /_.:=+@-]+$", + "type": "string" + }, + "Value": { + "maxLength": 256, + "minLength": 0, + "pattern": "^[A-Za-z0-9 /_.:=+@-]*$", + "type": "string" + } + }, + "required": [ + "Key", + "Value" + ], + "type": "object" + }, + "UriString": { + "maxLength": 10280, + "minLength": 1, + "pattern": "[\\u0020-\\uD7FF\\uE000-\\uFFFD\\uD800\\uDBFF-\\uDC00\\uDFFF\\r\\n\\t]*", + "type": "string" + }, + "WorkerConfiguration": { + "additionalProperties": false, + "properties": { + "Cpu": { + "$ref": "#/definitions/CpuSize" + }, + "Disk": { + "$ref": "#/definitions/DiskSize" + }, + "DiskType": { + "$ref": "#/definitions/DiskType" + }, + "Memory": { + "$ref": "#/definitions/MemorySize" + } + }, + "required": [ + "Cpu", + "Memory" + ], + "type": "object" + }, + "WorkerTypeSpecificationInput": { + "additionalProperties": false, + "properties": { + "ImageConfiguration": { + "$ref": "#/definitions/ImageConfigurationInput" + } + }, + "type": "object" + }, + "WorkerTypeSpecificationInputMap": { + "additionalProperties": false, + "patternProperties": { + "^[a-zA-Z]+[-_]*[a-zA-Z]+$": { + "$ref": "#/definitions/WorkerTypeSpecificationInput" + } + }, + "type": "object" + }, + "WorkerTypeString": { + "maxLength": 50, + "minLength": 1, + "pattern": "^[a-zA-Z]+[-_]*[a-zA-Z]+$", + "type": "string" + } + }, + "primaryIdentifier": [ + "/properties/ApplicationId" + ], + "properties": { + "ApplicationId": { + "maxLength": 64, + "minLength": 1, + "type": "string" + }, + "Architecture": { + "$ref": "#/definitions/Architecture" + }, + "Arn": { + "pattern": "^arn:(aws[a-zA-Z0-9-]*):emr-serverless:.+:(\\d{12}):\\/applications\\/[0-9a-zA-Z]+$", + "type": "string" + }, + "AutoStartConfiguration": { + "$ref": "#/definitions/AutoStartConfiguration" + }, + "AutoStopConfiguration": { + "$ref": "#/definitions/AutoStopConfiguration" + }, + "ImageConfiguration": { + "$ref": "#/definitions/ImageConfigurationInput" + }, + "InitialCapacity": { + "$ref": "#/definitions/InitialCapacityConfigMap" + }, + "InteractiveConfiguration": { + "$ref": "#/definitions/InteractiveConfiguration" + }, + "MaximumCapacity": { + "$ref": "#/definitions/MaximumAllowedResources" + }, + "MonitoringConfiguration": { + "$ref": "#/definitions/MonitoringConfiguration" + }, + "Name": { + "maxLength": 64, + "minLength": 1, + "pattern": "^[A-Za-z0-9._\\/#-]+$", + "type": "string" + }, + "NetworkConfiguration": { + "$ref": "#/definitions/NetworkConfiguration" + }, + "ReleaseLabel": { + "maxLength": 64, + "minLength": 1, + "pattern": "^[A-Za-z0-9._/-]+$", + "type": "string" + }, + "RuntimeConfiguration": { + "$ref": "#/definitions/ConfigurationList" + }, + "SchedulerConfiguration": { + "$ref": "#/definitions/SchedulerConfiguration" + }, + "Tags": { + "insertionOrder": false, + "items": { + "$ref": "#/definitions/Tag" + }, + "type": "array", + "uniqueItems": true + }, + "Type": { + "type": "string" + }, + "WorkerTypeSpecifications": { + "$ref": "#/definitions/WorkerTypeSpecificationInputMap" + } + }, + "readOnlyProperties": [ + "/properties/Arn", + "/properties/ApplicationId" + ], + "required": [ + "ReleaseLabel", + "Type" + ], + "sourceUrl": "https://github.com/aws-cloudformation/aws-cloudformation-rpdk.git", + "tagging": { + "cloudFormationSystemTags": false, + "tagOnCreate": true, + "tagProperty": "/properties/Tags", + "tagUpdatable": true, + "taggable": true + }, + "typeName": "AWS::EMRServerless::Application" +} diff --git a/src/cfnlint/data/schemas/providers/eu_south_1/aws-fsx-filesystem.json b/src/cfnlint/data/schemas/providers/eu_south_1/aws-fsx-filesystem.json index f63c43e724..f6dacdc4b5 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_1/aws-fsx-filesystem.json +++ b/src/cfnlint/data/schemas/providers/eu_south_1/aws-fsx-filesystem.json @@ -418,7 +418,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_south_1/aws-m2-environment.json b/src/cfnlint/data/schemas/providers/eu_south_1/aws-m2-environment.json index 65f6cde82f..eefe1e876a 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_1/aws-m2-environment.json +++ b/src/cfnlint/data/schemas/providers/eu_south_1/aws-m2-environment.json @@ -170,7 +170,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^\\S{1,50}$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/eu_south_1/aws-opsworks-layer.json b/src/cfnlint/data/schemas/providers/eu_south_1/aws-opsworks-layer.json index 9c1034b219..6108ba70de 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_1/aws-opsworks-layer.json +++ b/src/cfnlint/data/schemas/providers/eu_south_1/aws-opsworks-layer.json @@ -191,7 +191,9 @@ "$ref": "#/definitions/Recipes" }, "CustomSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_south_1/aws-timestream-influxdbinstance.json b/src/cfnlint/data/schemas/providers/eu_south_1/aws-timestream-influxdbinstance.json index 3cd225dc53..bfd94ca75f 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_1/aws-timestream-influxdbinstance.json +++ b/src/cfnlint/data/schemas/providers/eu_south_1/aws-timestream-influxdbinstance.json @@ -191,8 +191,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/eu_south_2/aws-ec2-clientvpnendpoint.json b/src/cfnlint/data/schemas/providers/eu_south_2/aws-ec2-clientvpnendpoint.json index 456d6c66ca..f6410e35e5 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_2/aws-ec2-clientvpnendpoint.json +++ b/src/cfnlint/data/schemas/providers/eu_south_2/aws-ec2-clientvpnendpoint.json @@ -191,7 +191,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_south_2/aws-m2-environment.json b/src/cfnlint/data/schemas/providers/eu_south_2/aws-m2-environment.json index 65f6cde82f..eefe1e876a 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_2/aws-m2-environment.json +++ b/src/cfnlint/data/schemas/providers/eu_south_2/aws-m2-environment.json @@ -170,7 +170,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^\\S{1,50}$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/eu_south_2/aws-memorydb-cluster.json b/src/cfnlint/data/schemas/providers/eu_south_2/aws-memorydb-cluster.json index cba3a3f129..b6bd694646 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_2/aws-memorydb-cluster.json +++ b/src/cfnlint/data/schemas/providers/eu_south_2/aws-memorydb-cluster.json @@ -118,7 +118,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_south_2/aws-opsworks-layer.json b/src/cfnlint/data/schemas/providers/eu_south_2/aws-opsworks-layer.json index 9c1034b219..6108ba70de 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_2/aws-opsworks-layer.json +++ b/src/cfnlint/data/schemas/providers/eu_south_2/aws-opsworks-layer.json @@ -191,7 +191,9 @@ "$ref": "#/definitions/Recipes" }, "CustomSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_south_2/aws-sagemaker-domain.json b/src/cfnlint/data/schemas/providers/eu_south_2/aws-sagemaker-domain.json index 94720f00bb..69e42e460e 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_2/aws-sagemaker-domain.json +++ b/src/cfnlint/data/schemas/providers/eu_south_2/aws-sagemaker-domain.json @@ -180,7 +180,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -254,7 +254,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -738,7 +738,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/eu_south_2/aws-sagemaker-userprofile.json b/src/cfnlint/data/schemas/providers/eu_south_2/aws-sagemaker-userprofile.json index 2d4d1a2f88..a21ea9e798 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_2/aws-sagemaker-userprofile.json +++ b/src/cfnlint/data/schemas/providers/eu_south_2/aws-sagemaker-userprofile.json @@ -571,7 +571,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/eu_south_2/aws-timestream-influxdbinstance.json b/src/cfnlint/data/schemas/providers/eu_south_2/aws-timestream-influxdbinstance.json index 3cd225dc53..bfd94ca75f 100644 --- a/src/cfnlint/data/schemas/providers/eu_south_2/aws-timestream-influxdbinstance.json +++ b/src/cfnlint/data/schemas/providers/eu_south_2/aws-timestream-influxdbinstance.json @@ -191,8 +191,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/eu_west_1/aws-mediaconnect-flow.json b/src/cfnlint/data/schemas/providers/eu_west_1/aws-mediaconnect-flow.json index ddfebe3e19..113156efe8 100644 --- a/src/cfnlint/data/schemas/providers/eu_west_1/aws-mediaconnect-flow.json +++ b/src/cfnlint/data/schemas/providers/eu_west_1/aws-mediaconnect-flow.json @@ -512,7 +512,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/eu_west_1/aws-pcs-cluster.json b/src/cfnlint/data/schemas/providers/eu_west_1/aws-pcs-cluster.json index bd9b718b7d..0eb3ff4219 100644 --- a/src/cfnlint/data/schemas/providers/eu_west_1/aws-pcs-cluster.json +++ b/src/cfnlint/data/schemas/providers/eu_west_1/aws-pcs-cluster.json @@ -64,6 +64,7 @@ "type": "object" }, "SecurityGroupId": { + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "sg-\\w{8,17}", "type": "string" }, @@ -139,6 +140,7 @@ "additionalProperties": false, "properties": { "SecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { "$ref": "#/definitions/SecurityGroupId" diff --git a/src/cfnlint/data/schemas/providers/eu_west_2/aws-appstream-imagebuilder.json b/src/cfnlint/data/schemas/providers/eu_west_2/aws-appstream-imagebuilder.json index 1f77bfb4b1..41919ec829 100644 --- a/src/cfnlint/data/schemas/providers/eu_west_2/aws-appstream-imagebuilder.json +++ b/src/cfnlint/data/schemas/providers/eu_west_2/aws-appstream-imagebuilder.json @@ -54,7 +54,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_west_2/aws-m2-environment.json b/src/cfnlint/data/schemas/providers/eu_west_2/aws-m2-environment.json index 65f6cde82f..eefe1e876a 100644 --- a/src/cfnlint/data/schemas/providers/eu_west_2/aws-m2-environment.json +++ b/src/cfnlint/data/schemas/providers/eu_west_2/aws-m2-environment.json @@ -170,7 +170,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^\\S{1,50}$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/eu_west_2/aws-nimblestudio-studiocomponent.json b/src/cfnlint/data/schemas/providers/eu_west_2/aws-nimblestudio-studiocomponent.json index 2604515a51..56f76f0c11 100644 --- a/src/cfnlint/data/schemas/providers/eu_west_2/aws-nimblestudio-studiocomponent.json +++ b/src/cfnlint/data/schemas/providers/eu_west_2/aws-nimblestudio-studiocomponent.json @@ -48,7 +48,9 @@ "type": "string" }, "Ec2SecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_west_2/aws-timestream-influxdbinstance.json b/src/cfnlint/data/schemas/providers/eu_west_2/aws-timestream-influxdbinstance.json index 3cd225dc53..bfd94ca75f 100644 --- a/src/cfnlint/data/schemas/providers/eu_west_2/aws-timestream-influxdbinstance.json +++ b/src/cfnlint/data/schemas/providers/eu_west_2/aws-timestream-influxdbinstance.json @@ -191,8 +191,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/eu_west_3/aws-ec2-clientvpnendpoint.json b/src/cfnlint/data/schemas/providers/eu_west_3/aws-ec2-clientvpnendpoint.json index 456d6c66ca..f6410e35e5 100644 --- a/src/cfnlint/data/schemas/providers/eu_west_3/aws-ec2-clientvpnendpoint.json +++ b/src/cfnlint/data/schemas/providers/eu_west_3/aws-ec2-clientvpnendpoint.json @@ -191,7 +191,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/eu_west_3/aws-m2-environment.json b/src/cfnlint/data/schemas/providers/eu_west_3/aws-m2-environment.json index 65f6cde82f..eefe1e876a 100644 --- a/src/cfnlint/data/schemas/providers/eu_west_3/aws-m2-environment.json +++ b/src/cfnlint/data/schemas/providers/eu_west_3/aws-m2-environment.json @@ -170,7 +170,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^\\S{1,50}$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/eu_west_3/aws-timestream-influxdbinstance.json b/src/cfnlint/data/schemas/providers/eu_west_3/aws-timestream-influxdbinstance.json index 3cd225dc53..bfd94ca75f 100644 --- a/src/cfnlint/data/schemas/providers/eu_west_3/aws-timestream-influxdbinstance.json +++ b/src/cfnlint/data/schemas/providers/eu_west_3/aws-timestream-influxdbinstance.json @@ -191,8 +191,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/il_central_1/aws-autoscaling-launchconfiguration.json b/src/cfnlint/data/schemas/providers/il_central_1/aws-autoscaling-launchconfiguration.json index 944f5608ad..fd40ebb2b7 100644 --- a/src/cfnlint/data/schemas/providers/il_central_1/aws-autoscaling-launchconfiguration.json +++ b/src/cfnlint/data/schemas/providers/il_central_1/aws-autoscaling-launchconfiguration.json @@ -175,7 +175,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/il_central_1/aws-cloudformation-typeactivation.json b/src/cfnlint/data/schemas/providers/il_central_1/aws-cloudformation-typeactivation.json index 730262bfac..ff8c82293d 100644 --- a/src/cfnlint/data/schemas/providers/il_central_1/aws-cloudformation-typeactivation.json +++ b/src/cfnlint/data/schemas/providers/il_central_1/aws-cloudformation-typeactivation.json @@ -14,6 +14,7 @@ "additionalProperties": false, "properties": { "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "^[\\.\\-_/#A-Za-z0-9]+$", diff --git a/src/cfnlint/data/schemas/providers/il_central_1/aws-ec2-clientvpnendpoint.json b/src/cfnlint/data/schemas/providers/il_central_1/aws-ec2-clientvpnendpoint.json index 456d6c66ca..f6410e35e5 100644 --- a/src/cfnlint/data/schemas/providers/il_central_1/aws-ec2-clientvpnendpoint.json +++ b/src/cfnlint/data/schemas/providers/il_central_1/aws-ec2-clientvpnendpoint.json @@ -191,7 +191,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/il_central_1/aws-ec2-spotfleet.json b/src/cfnlint/data/schemas/providers/il_central_1/aws-ec2-spotfleet.json index e88a9d9272..7a7dd681df 100644 --- a/src/cfnlint/data/schemas/providers/il_central_1/aws-ec2-spotfleet.json +++ b/src/cfnlint/data/schemas/providers/il_central_1/aws-ec2-spotfleet.json @@ -109,7 +109,7 @@ }, "GroupIdentifier": { "additionalProperties": false, - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "properties": { "GroupId": { "type": "string" diff --git a/src/cfnlint/data/schemas/providers/il_central_1/aws-m2-environment.json b/src/cfnlint/data/schemas/providers/il_central_1/aws-m2-environment.json index 65f6cde82f..eefe1e876a 100644 --- a/src/cfnlint/data/schemas/providers/il_central_1/aws-m2-environment.json +++ b/src/cfnlint/data/schemas/providers/il_central_1/aws-m2-environment.json @@ -170,7 +170,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^\\S{1,50}$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/il_central_1/aws-opsworks-layer.json b/src/cfnlint/data/schemas/providers/il_central_1/aws-opsworks-layer.json index 9c1034b219..6108ba70de 100644 --- a/src/cfnlint/data/schemas/providers/il_central_1/aws-opsworks-layer.json +++ b/src/cfnlint/data/schemas/providers/il_central_1/aws-opsworks-layer.json @@ -191,7 +191,9 @@ "$ref": "#/definitions/Recipes" }, "CustomSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/il_central_1/aws-sagemaker-domain.json b/src/cfnlint/data/schemas/providers/il_central_1/aws-sagemaker-domain.json index 94720f00bb..69e42e460e 100644 --- a/src/cfnlint/data/schemas/providers/il_central_1/aws-sagemaker-domain.json +++ b/src/cfnlint/data/schemas/providers/il_central_1/aws-sagemaker-domain.json @@ -180,7 +180,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -254,7 +254,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -738,7 +738,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/il_central_1/aws-sagemaker-userprofile.json b/src/cfnlint/data/schemas/providers/il_central_1/aws-sagemaker-userprofile.json index 2d4d1a2f88..a21ea9e798 100644 --- a/src/cfnlint/data/schemas/providers/il_central_1/aws-sagemaker-userprofile.json +++ b/src/cfnlint/data/schemas/providers/il_central_1/aws-sagemaker-userprofile.json @@ -571,7 +571,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/me_central_1/aws-ec2-clientvpnendpoint.json b/src/cfnlint/data/schemas/providers/me_central_1/aws-ec2-clientvpnendpoint.json index 456d6c66ca..f6410e35e5 100644 --- a/src/cfnlint/data/schemas/providers/me_central_1/aws-ec2-clientvpnendpoint.json +++ b/src/cfnlint/data/schemas/providers/me_central_1/aws-ec2-clientvpnendpoint.json @@ -191,7 +191,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/me_central_1/aws-fsx-filesystem.json b/src/cfnlint/data/schemas/providers/me_central_1/aws-fsx-filesystem.json index f63c43e724..f6dacdc4b5 100644 --- a/src/cfnlint/data/schemas/providers/me_central_1/aws-fsx-filesystem.json +++ b/src/cfnlint/data/schemas/providers/me_central_1/aws-fsx-filesystem.json @@ -418,7 +418,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/me_central_1/aws-opsworks-layer.json b/src/cfnlint/data/schemas/providers/me_central_1/aws-opsworks-layer.json index 9c1034b219..6108ba70de 100644 --- a/src/cfnlint/data/schemas/providers/me_central_1/aws-opsworks-layer.json +++ b/src/cfnlint/data/schemas/providers/me_central_1/aws-opsworks-layer.json @@ -191,7 +191,9 @@ "$ref": "#/definitions/Recipes" }, "CustomSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/me_central_1/aws-sagemaker-domain.json b/src/cfnlint/data/schemas/providers/me_central_1/aws-sagemaker-domain.json index 94720f00bb..69e42e460e 100644 --- a/src/cfnlint/data/schemas/providers/me_central_1/aws-sagemaker-domain.json +++ b/src/cfnlint/data/schemas/providers/me_central_1/aws-sagemaker-domain.json @@ -180,7 +180,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -254,7 +254,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -738,7 +738,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/me_central_1/aws-sagemaker-userprofile.json b/src/cfnlint/data/schemas/providers/me_central_1/aws-sagemaker-userprofile.json index 2d4d1a2f88..a21ea9e798 100644 --- a/src/cfnlint/data/schemas/providers/me_central_1/aws-sagemaker-userprofile.json +++ b/src/cfnlint/data/schemas/providers/me_central_1/aws-sagemaker-userprofile.json @@ -571,7 +571,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/me_central_1/aws-timestream-influxdbinstance.json b/src/cfnlint/data/schemas/providers/me_central_1/aws-timestream-influxdbinstance.json index 3cd225dc53..bfd94ca75f 100644 --- a/src/cfnlint/data/schemas/providers/me_central_1/aws-timestream-influxdbinstance.json +++ b/src/cfnlint/data/schemas/providers/me_central_1/aws-timestream-influxdbinstance.json @@ -191,8 +191,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/sa_east_1/aws-codebuild-fleet.json b/src/cfnlint/data/schemas/providers/sa_east_1/aws-codebuild-fleet.json index 85c9bd3cbe..05ad47e89e 100644 --- a/src/cfnlint/data/schemas/providers/sa_east_1/aws-codebuild-fleet.json +++ b/src/cfnlint/data/schemas/providers/sa_east_1/aws-codebuild-fleet.json @@ -136,7 +136,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/sa_east_1/aws-fsx-filesystem.json b/src/cfnlint/data/schemas/providers/sa_east_1/aws-fsx-filesystem.json index f63c43e724..f6dacdc4b5 100644 --- a/src/cfnlint/data/schemas/providers/sa_east_1/aws-fsx-filesystem.json +++ b/src/cfnlint/data/schemas/providers/sa_east_1/aws-fsx-filesystem.json @@ -418,7 +418,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/sa_east_1/aws-memorydb-cluster.json b/src/cfnlint/data/schemas/providers/sa_east_1/aws-memorydb-cluster.json index cba3a3f129..b6bd694646 100644 --- a/src/cfnlint/data/schemas/providers/sa_east_1/aws-memorydb-cluster.json +++ b/src/cfnlint/data/schemas/providers/sa_east_1/aws-memorydb-cluster.json @@ -118,7 +118,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-amazonmq-broker.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-amazonmq-broker.json index 7fe0163812..e5dea320ff 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-amazonmq-broker.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-amazonmq-broker.json @@ -284,7 +284,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-apigatewayv2-vpclink.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-apigatewayv2-vpclink.json index 2bbef55950..89a4f86df6 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-apigatewayv2-vpclink.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-apigatewayv2-vpclink.json @@ -14,7 +14,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-applicationinsights-application.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-applicationinsights-application.json index c4d742ff81..abc11c1164 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-applicationinsights-application.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-applicationinsights-application.json @@ -264,6 +264,7 @@ "type": "string" }, "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "[\\.\\-_/#A-Za-z0-9]+", @@ -498,6 +499,7 @@ "type": "string" }, "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "[\\.\\-_/#A-Za-z0-9]+", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-apprunner-vpcconnector.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-apprunner-vpcconnector.json index 465cf85ac0..73b85714d8 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-apprunner-vpcconnector.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-apprunner-vpcconnector.json @@ -29,7 +29,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-appstream-appblockbuilder.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-appstream-appblockbuilder.json index 7843e92fad..b66bd5040d 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-appstream-appblockbuilder.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-appstream-appblockbuilder.json @@ -55,7 +55,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-appstream-fleet.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-appstream-fleet.json index 74056a53b2..5528728618 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-appstream-fleet.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-appstream-fleet.json @@ -67,7 +67,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-appstream-imagebuilder.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-appstream-imagebuilder.json index 274a79b365..9c28191250 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-appstream-imagebuilder.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-appstream-imagebuilder.json @@ -54,7 +54,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-aps-scraper.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-aps-scraper.json index bfc2f437e6..c0f9e778e6 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-aps-scraper.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-aps-scraper.json @@ -47,7 +47,7 @@ "type": "object" }, "SecurityGroupId": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^sg-[0-9a-z]+$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-autoscaling-launchconfiguration.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-autoscaling-launchconfiguration.json index b0b305b391..633dc82458 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-autoscaling-launchconfiguration.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-autoscaling-launchconfiguration.json @@ -190,7 +190,7 @@ } } ], - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-b2bi-profile.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-b2bi-profile.json index 2eef77b233..de80895bff 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-b2bi-profile.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-b2bi-profile.json @@ -52,6 +52,7 @@ "type": "string" }, "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-batch-computeenvironment.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-batch-computeenvironment.json index 7b85629235..7a9dfb0e03 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-batch-computeenvironment.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-batch-computeenvironment.json @@ -88,7 +88,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-hookversion.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-hookversion.json index ade7b162c0..c56b1cf916 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-hookversion.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-hookversion.json @@ -11,6 +11,7 @@ "additionalProperties": false, "properties": { "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "^[\\.\\-_/#A-Za-z0-9]+$", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-macro.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-macro.json index c90fb34287..29e46b90f7 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-macro.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-macro.json @@ -17,6 +17,7 @@ "type": "string" }, "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "type": "string" }, "LogRoleARN": { diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-resourceversion.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-resourceversion.json index 320e8edf6b..222ba6546c 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-resourceversion.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-resourceversion.json @@ -11,6 +11,7 @@ "additionalProperties": false, "properties": { "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "^[\\.\\-_/#A-Za-z0-9]+$", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-typeactivation.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-typeactivation.json index f48e6739ce..d1e201324f 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-typeactivation.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-cloudformation-typeactivation.json @@ -8,6 +8,7 @@ "additionalProperties": false, "properties": { "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "^[\\.\\-_/#A-Za-z0-9]+$", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-codebuild-fleet.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-codebuild-fleet.json index e462ffd498..669fd4831b 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-codebuild-fleet.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-codebuild-fleet.json @@ -136,7 +136,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-codebuild-project.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-codebuild-project.json index 1220933700..c58b5299a2 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-codebuild-project.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-codebuild-project.json @@ -467,7 +467,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-comprehend-documentclassifier.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-comprehend-documentclassifier.json index a88cbd0e18..8c18954ce9 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-comprehend-documentclassifier.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-comprehend-documentclassifier.json @@ -194,7 +194,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "minLength": 1, "pattern": "[-0-9a-zA-Z]+", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-comprehend-flywheel.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-comprehend-flywheel.json index ebd42c672b..5d4dfdc8ae 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-comprehend-flywheel.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-comprehend-flywheel.json @@ -143,7 +143,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "minLength": 1, "pattern": "[-0-9a-zA-Z]+", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-dax-cluster.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-dax-cluster.json index ca8b7124a9..cb53ea4584 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-dax-cluster.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-dax-cluster.json @@ -75,7 +75,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-deadline-licenseendpoint.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-deadline-licenseendpoint.json index 16e533d92b..275bde0920 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-deadline-licenseendpoint.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-deadline-licenseendpoint.json @@ -54,7 +54,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "sg-[\\w]{1,120}", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-dms-replicationconfig.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-dms-replicationconfig.json index 14df537105..f6bb4da400 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-dms-replicationconfig.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-dms-replicationconfig.json @@ -37,7 +37,9 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-dms-replicationinstance.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-dms-replicationinstance.json index 3d4dfcb1dc..2d24132ed1 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-dms-replicationinstance.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-dms-replicationinstance.json @@ -87,7 +87,9 @@ "uniqueItems": false }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-docdb-dbcluster.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-docdb-dbcluster.json index 7b0f6cf8cc..f5f0cda37c 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-docdb-dbcluster.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-docdb-dbcluster.json @@ -162,7 +162,9 @@ "type": "boolean" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-docdbelastic-cluster.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-docdbelastic-cluster.json index b5f8028a3e..e8591fad39 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-docdbelastic-cluster.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-docdbelastic-cluster.json @@ -98,8 +98,10 @@ "uniqueItems": true }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-clientvpnendpoint.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-clientvpnendpoint.json index 7727402f2d..1d14b07222 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-clientvpnendpoint.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-clientvpnendpoint.json @@ -194,7 +194,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-flowlog.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-flowlog.json index 6a92bc9eac..62c7c46a02 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-flowlog.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-flowlog.json @@ -83,6 +83,7 @@ "type": "string" }, "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "type": "string" }, "MaxAggregationInterval": { diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-instance.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-instance.json index ebe6c81149..8652b2d11d 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-instance.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-instance.json @@ -233,8 +233,10 @@ "type": "string" }, "GroupSet": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", @@ -1463,7 +1465,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", @@ -1473,7 +1475,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-instanceconnectendpoint.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-instanceconnectendpoint.json index e9866f8370..bbfbc2a6fa 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-instanceconnectendpoint.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-instanceconnectendpoint.json @@ -8,7 +8,7 @@ ], "definitions": { "SecurityGroupId": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "Tag": { diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-launchtemplate.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-launchtemplate.json index 7b97561a5f..1e15e87231 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-launchtemplate.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-launchtemplate.json @@ -1470,7 +1470,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", @@ -1479,7 +1479,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-networkinterface.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-networkinterface.json index 45e5286ce7..61382d1f9e 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-networkinterface.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-networkinterface.json @@ -118,8 +118,10 @@ "type": "boolean" }, "GroupSet": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-securitygroup.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-securitygroup.json index 3de009dd36..f5f5f4cfff 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-securitygroup.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-securitygroup.json @@ -23,7 +23,7 @@ "type": "string" }, "DestinationSecurityGroupId": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "FromPort": { @@ -72,11 +72,11 @@ "type": "string" }, "SourceSecurityGroupId": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "SourceSecurityGroupName": { - "format": "AWS::EC2::SecurityGroup.GroupName", + "format": "AWS::EC2::SecurityGroup.Name", "type": "string" }, "SourceSecurityGroupOwnerId": { @@ -132,14 +132,22 @@ "type": "string" }, "GroupId": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "GroupName": { - "format": "AWS::EC2::SecurityGroup.GroupName", + "format": "AWS::EC2::SecurityGroup.Name", "type": "string" }, "Id": { + "anyOf": [ + { + "format": "AWS::EC2::SecurityGroup.Id" + }, + { + "format": "AWS::EC2::SecurityGroup.Name" + } + ], "type": "string" }, "SecurityGroupEgress": { diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-securitygroupegress.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-securitygroupegress.json index e8595b3d24..61bb5cc1cc 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-securitygroupegress.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-securitygroupegress.json @@ -27,7 +27,7 @@ "type": "string" }, "DestinationSecurityGroupId": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "FromPort": { @@ -35,7 +35,7 @@ "type": "integer" }, "GroupId": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "Id": { diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-securitygroupingress.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-securitygroupingress.json index c71c63d050..fa950e179e 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-securitygroupingress.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-securitygroupingress.json @@ -31,7 +31,7 @@ "type": "integer" }, "GroupId": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "GroupName": { @@ -47,11 +47,11 @@ "type": "string" }, "SourceSecurityGroupId": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "SourceSecurityGroupName": { - "format": "AWS::EC2::SecurityGroup.GroupName", + "format": "AWS::EC2::SecurityGroup.Name", "type": "string" }, "SourceSecurityGroupOwnerId": { diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-spotfleet.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-spotfleet.json index 0b349f5d4b..47d5f81585 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-spotfleet.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-spotfleet.json @@ -191,7 +191,7 @@ }, "GroupIdentifier": { "additionalProperties": false, - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "properties": { "GroupId": { "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-verifiedaccessendpoint.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-verifiedaccessendpoint.json index 6431fdd379..6d447b6039 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-verifiedaccessendpoint.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-verifiedaccessendpoint.json @@ -64,7 +64,7 @@ "type": "object" }, "SecurityGroupId": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "SseSpecification": { diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-vpc.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-vpc.json index 4627a755b2..65c91bef46 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-vpc.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-vpc.json @@ -54,7 +54,7 @@ "type": "string" }, "DefaultSecurityGroup": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "insertionOrder": false, "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-vpcendpoint.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-vpcendpoint.json index 740e9f1a84..2c0f4214d6 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-vpcendpoint.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ec2-vpcendpoint.json @@ -135,7 +135,7 @@ } } ], - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ecs-service.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ecs-service.json index 8187242144..1893e7b502 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ecs-service.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ecs-service.json @@ -22,7 +22,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ecs-taskset.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ecs-taskset.json index 0a6601f5ff..dbfd79fe76 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ecs-taskset.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ecs-taskset.json @@ -26,7 +26,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-efs-mounttarget.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-efs-mounttarget.json index be47cdd105..749e0bdf05 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-efs-mounttarget.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-efs-mounttarget.json @@ -24,7 +24,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^sg-[0-9a-f]{8,40}", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-eks-cluster.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-eks-cluster.json index 3d2a787c19..6c268f2670 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-eks-cluster.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-eks-cluster.json @@ -271,7 +271,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "minItems": 1, "type": "string" }, @@ -360,6 +360,7 @@ "type": "string" }, "ClusterSecurityGroupId": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "ComputeConfig": { diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticache-cachecluster.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticache-cachecluster.json index f980ba18f3..960514a54a 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticache-cachecluster.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticache-cachecluster.json @@ -209,7 +209,9 @@ "type": "boolean" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticache-replicationgroup.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticache-replicationgroup.json index 80dd855768..f4d6ed688e 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticache-replicationgroup.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticache-replicationgroup.json @@ -275,7 +275,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticache-serverlesscache.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticache-serverlesscache.json index b532d4d656..cdbd463e6e 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticache-serverlesscache.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticache-serverlesscache.json @@ -130,7 +130,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticloadbalancing-loadbalancer.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticloadbalancing-loadbalancer.json index f0e6d5b7b1..663d99a780 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticloadbalancing-loadbalancer.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticloadbalancing-loadbalancer.json @@ -288,7 +288,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", @@ -297,7 +297,7 @@ "SourceSecurityGroup": { "properties": { "GroupName": { - "format": "AWS::EC2::SecurityGroup.GroupName", + "format": "AWS::EC2::SecurityGroup.Name", "type": "string" }, "OwnerAlias": { diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticloadbalancingv2-loadbalancer.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticloadbalancingv2-loadbalancer.json index 17b302a6fa..9afefea636 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticloadbalancingv2-loadbalancer.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticloadbalancingv2-loadbalancer.json @@ -138,7 +138,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticsearch-domain.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticsearch-domain.json index a32c5bfa89..e53c6ab575 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticsearch-domain.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-elasticsearch-domain.json @@ -206,7 +206,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-emrserverless-application.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-emrserverless-application.json index 7d091104d9..c7c3d3e2b1 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-emrserverless-application.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-emrserverless-application.json @@ -216,6 +216,7 @@ "type": "object" }, "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "^[\\.\\-_/#A-Za-z0-9]+$", @@ -380,7 +381,7 @@ "type": "object" }, "SecurityGroupId": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "minLength": 1, "pattern": "[-0-9a-zA-Z]+.*", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-events-rule.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-events-rule.json index e516afe4d0..a7a80d295b 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-events-rule.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-events-rule.json @@ -33,7 +33,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": true, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-fsx-filesystem.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-fsx-filesystem.json index 0f8186218c..d94b46f234 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-fsx-filesystem.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-fsx-filesystem.json @@ -433,7 +433,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-glue-connection.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-glue-connection.json index 462d228c89..fc90edca92 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-glue-connection.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-glue-connection.json @@ -77,7 +77,9 @@ "type": "string" }, "SecurityGroupIdList": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-glue-devendpoint.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-glue-devendpoint.json index d76c7eea4e..a78af81e9c 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-glue-devendpoint.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-glue-devendpoint.json @@ -54,7 +54,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-grafana-workspace.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-grafana-workspace.json index e15f713a8a..0f5cbf8681 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-grafana-workspace.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-grafana-workspace.json @@ -190,7 +190,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 255, "minLength": 1, "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-groundstation-dataflowendpointgroup.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-groundstation-dataflowendpointgroup.json index ebc851524e..f7c8440395 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-groundstation-dataflowendpointgroup.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-groundstation-dataflowendpointgroup.json @@ -142,7 +142,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-imagebuilder-infrastructureconfiguration.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-imagebuilder-infrastructureconfiguration.json index caf0c5be46..e04069ec40 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-imagebuilder-infrastructureconfiguration.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-imagebuilder-infrastructureconfiguration.json @@ -131,7 +131,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-iot-topicrule.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-iot-topicrule.json index 10d6b95d16..a1bb29ff5e 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-iot-topicrule.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-iot-topicrule.json @@ -172,6 +172,7 @@ "type": "boolean" }, "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "type": "string" }, "RoleArn": { diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-iot-topicruledestination.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-iot-topicruledestination.json index ef811074b6..564b640f2c 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-iot-topicruledestination.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-iot-topicruledestination.json @@ -31,7 +31,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-ivschat-loggingconfiguration.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-ivschat-loggingconfiguration.json index 12efbbcba4..2d6b6e0ab0 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-ivschat-loggingconfiguration.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-ivschat-loggingconfiguration.json @@ -5,6 +5,7 @@ "additionalProperties": false, "properties": { "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "^[\\.\\-_/#A-Za-z0-9]+$", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-kafkaconnect-connector.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-kafkaconnect-connector.json index fb3e8b0810..499a61e451 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-kafkaconnect-connector.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-kafkaconnect-connector.json @@ -308,7 +308,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-kendra-datasource.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-kendra-datasource.json index 3cb6b4001c..436ce9e5db 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-kendra-datasource.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-kendra-datasource.json @@ -539,7 +539,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 200, "minLength": 1, "pattern": "[\\-0-9a-zA-Z]+", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-kinesisanalyticsv2-application.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-kinesisanalyticsv2-application.json index cda20eb996..2579cdfb81 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-kinesisanalyticsv2-application.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-kinesisanalyticsv2-application.json @@ -685,7 +685,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-kinesisfirehose-deliverystream.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-kinesisfirehose-deliverystream.json index b57ada469d..8d955c80dc 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-kinesisfirehose-deliverystream.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-kinesisfirehose-deliverystream.json @@ -255,6 +255,7 @@ "type": "boolean" }, "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "pattern": "[\\.\\-_/#A-Za-z0-9]*", "relationshipRef": { "propertyPath": "/properties/LogGroupName", @@ -1809,7 +1810,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 1024, "minLength": 1, "pattern": "^\\S+$", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-lambda-function.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-lambda-function.json index 22890891f3..e785c97131 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-lambda-function.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-lambda-function.json @@ -269,7 +269,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-loggroup.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-loggroup.json index bf9e5c905f..1dd0d09544 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-loggroup.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-loggroup.json @@ -61,6 +61,7 @@ "type": "string" }, "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "^[.\\-_/#A-Za-z0-9]{1,512}\\Z", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-logstream.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-logstream.json index b68cace645..53813b6efc 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-logstream.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-logstream.json @@ -10,6 +10,7 @@ ], "properties": { "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "pattern": "[\\.\\-_/#A-Za-z0-9]+", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-metricfilter.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-metricfilter.json index 74039e4c4d..6e4964e5cd 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-metricfilter.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-metricfilter.json @@ -120,6 +120,7 @@ "type": "string" }, "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "^[.\\-_/#A-Za-z0-9]{1,512}", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-subscriptionfilter.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-subscriptionfilter.json index 0b07130b61..97a69e12d5 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-subscriptionfilter.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-logs-subscriptionfilter.json @@ -31,6 +31,7 @@ "type": "string" }, "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "pattern": "[\\.\\-_/#A-Za-z0-9]+", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-lookoutmetrics-anomalydetector.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-lookoutmetrics-anomalydetector.json index 335d502692..b0962a07c6 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-lookoutmetrics-anomalydetector.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-lookoutmetrics-anomalydetector.json @@ -389,7 +389,9 @@ "type": "string" }, "SecurityGroupIdList": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 255, "minLength": 1, "pattern": "[-0-9a-zA-Z]+", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-m2-environment.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-m2-environment.json index b666c811d0..c903863123 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-m2-environment.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-m2-environment.json @@ -170,7 +170,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^\\S{1,50}$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-mediaconnect-flow.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-mediaconnect-flow.json index ad664f0d65..107cc06e52 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-mediaconnect-flow.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-mediaconnect-flow.json @@ -427,7 +427,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-mediaconnect-flowvpcinterface.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-mediaconnect-flowvpcinterface.json index 58ac32061d..928b7e25ea 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-mediaconnect-flowvpcinterface.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-mediaconnect-flowvpcinterface.json @@ -27,7 +27,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-medialive-channel.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-medialive-channel.json index a6c907c033..777ee2e403 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-medialive-channel.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-medialive-channel.json @@ -3472,7 +3472,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-medialive-input.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-medialive-input.json index da0d73a7e8..5be348f099 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-medialive-input.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-medialive-input.json @@ -70,7 +70,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", @@ -195,7 +195,9 @@ "type": "string" }, "InputSecurityGroups": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-mediapackage-channel.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-mediapackage-channel.json index 1509a719dd..a814e1680e 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-mediapackage-channel.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-mediapackage-channel.json @@ -45,6 +45,7 @@ "additionalProperties": false, "properties": { "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 256, "minLength": 1, "pattern": "\\A^(\\/aws\\/MediaPackage\\/)[a-zA-Z0-9_-]+\\Z", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-mediapackage-packaginggroup.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-mediapackage-packaginggroup.json index 42479c4b7b..a4bb1b0122 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-mediapackage-packaginggroup.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-mediapackage-packaginggroup.json @@ -25,6 +25,7 @@ "additionalProperties": false, "properties": { "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "\\A\\/aws\\/MediaPackage\\/[0-9a-zA-Z-_\\/\\.#]+\\Z", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-memorydb-cluster.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-memorydb-cluster.json index c90500431e..8a4a91ca09 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-memorydb-cluster.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-memorydb-cluster.json @@ -122,7 +122,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-cluster.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-cluster.json index e39b3b1ddc..3b7cbcc5cc 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-cluster.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-cluster.json @@ -55,7 +55,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-replicator.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-replicator.json index 5fa8e72b92..67eb2ee789 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-replicator.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-replicator.json @@ -90,7 +90,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 16, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-serverlesscluster.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-serverlesscluster.json index a1b19026c3..bfaf898716 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-serverlesscluster.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-serverlesscluster.json @@ -50,7 +50,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-vpcconnection.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-vpcconnection.json index bcd90dc9a2..10a81789a7 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-vpcconnection.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-msk-vpcconnection.json @@ -31,7 +31,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^(sg-)([a-z0-9]+)\\Z", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-mwaa-environment.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-mwaa-environment.json index 6a6f79533a..da19bab388 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-mwaa-environment.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-mwaa-environment.json @@ -259,7 +259,7 @@ "type": "integer" }, "SecurityGroupId": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 1024, "minLength": 1, "pattern": "sg-[a-zA-Z0-9\\-._]+", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-neptune-dbcluster.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-neptune-dbcluster.json index d95be4e1c1..9648ef1230 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-neptune-dbcluster.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-neptune-dbcluster.json @@ -184,8 +184,10 @@ "type": "boolean" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": true, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-neptunegraph-privategraphendpoint.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-neptunegraph-privategraphendpoint.json index a1758d3570..12ec1615f3 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-neptunegraph-privategraphendpoint.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-neptunegraph-privategraphendpoint.json @@ -27,7 +27,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-nimblestudio-studiocomponent.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-nimblestudio-studiocomponent.json index 99ed08b6c2..aaf960a290 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-nimblestudio-studiocomponent.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-nimblestudio-studiocomponent.json @@ -139,7 +139,9 @@ "type": "string" }, "Ec2SecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-opensearchserverless-vpcendpoint.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-opensearchserverless-vpcendpoint.json index 40395738d3..2b2e6ab1f0 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-opensearchserverless-vpcendpoint.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-opensearchserverless-vpcendpoint.json @@ -29,7 +29,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 128, "minLength": 1, "pattern": "^[\\w+\\-]+$", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-opensearchservice-domain.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-opensearchservice-domain.json index f046602b0f..89cff8945e 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-opensearchservice-domain.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-opensearchservice-domain.json @@ -428,7 +428,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-opsworks-layer.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-opsworks-layer.json index 8f9f58f354..825d76ba97 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-opsworks-layer.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-opsworks-layer.json @@ -191,7 +191,9 @@ "$ref": "#/definitions/Recipes" }, "CustomSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-opsworkscm-server.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-opsworkscm-server.json index 3309d7b316..b756e67f7d 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-opsworkscm-server.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-opsworkscm-server.json @@ -149,7 +149,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 10000, "pattern": "(?s).*", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-osis-pipeline.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-osis-pipeline.json index 72ea7dcfe9..a69c255d24 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-osis-pipeline.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-osis-pipeline.json @@ -95,7 +95,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 20, "minLength": 11, "pattern": "sg-\\w{8}(\\w{9})?", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-pcaconnectorad-connector.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-pcaconnectorad-connector.json index 570ec920eb..2e7cfbab82 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-pcaconnectorad-connector.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-pcaconnectorad-connector.json @@ -21,7 +21,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 20, "minLength": 11, "pattern": "^(?:sg-[0-9a-f]{8}|sg-[0-9a-f]{17})$", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-pcs-cluster.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-pcs-cluster.json index b31f23ede6..f8507115e2 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-pcs-cluster.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-pcs-cluster.json @@ -64,6 +64,7 @@ "type": "object" }, "SecurityGroupId": { + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "sg-\\w{8,17}", "type": "string" }, @@ -140,6 +141,7 @@ "additionalProperties": false, "properties": { "SecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { "$ref": "#/definitions/SecurityGroupId" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-pcs-computenodegroup.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-pcs-computenodegroup.json index 9a2f156332..c97bd143ab 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-pcs-computenodegroup.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-pcs-computenodegroup.json @@ -52,6 +52,7 @@ ], "properties": { "AmiId": { + "format": "AWS::EC2::Image.Id", "pattern": "^ami-[a-z0-9]+$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-qbusiness-datasource.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-qbusiness-datasource.json index 29d4b21d76..068c8ccf94 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-qbusiness-datasource.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-qbusiness-datasource.json @@ -29,7 +29,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 200, "minLength": 1, "pattern": "[-0-9a-zA-Z]+", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-quicksight-vpcconnection.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-quicksight-vpcconnection.json index 1124a8d5c6..8b581e73cb 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-quicksight-vpcconnection.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-quicksight-vpcconnection.json @@ -144,7 +144,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 255, "minLength": 1, "pattern": "^sg-[0-9a-z]*$", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-rds-dbcluster.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-rds-dbcluster.json index 8faa55363c..b2a8132eb3 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-rds-dbcluster.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-rds-dbcluster.json @@ -360,7 +360,9 @@ "type": "boolean" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-rds-dbproxy.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-rds-dbproxy.json index 01497c9ae9..8eaedd721f 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-rds-dbproxy.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-rds-dbproxy.json @@ -113,8 +113,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "minItems": 1, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-rds-dbproxyendpoint.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-rds-dbproxyendpoint.json index 62cd5e6a33..8a8c4d69ee 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-rds-dbproxyendpoint.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-rds-dbproxyendpoint.json @@ -67,8 +67,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "minItems": 1, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-redshift-cluster.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-redshift-cluster.json index b9bda6586e..2cacabfa4c 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-redshift-cluster.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-redshift-cluster.json @@ -314,8 +314,10 @@ "uniqueItems": false }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "relationshipRef": { "propertyPath": "/properties/VpcId", "typeName": "AWS::EC2::VPC" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-redshift-endpointaccess.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-redshift-endpointaccess.json index 45310c33e5..e2b276a19f 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-redshift-endpointaccess.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-redshift-endpointaccess.json @@ -45,6 +45,7 @@ "type": "string" }, "VpcSecurityGroupId": { + "format": "AWS::EC2::SecurityGroup.Id", "relationshipRef": { "propertyPath": "/properties/Id", "typeName": "AWS::EC2::SecurityGroup" @@ -115,8 +116,10 @@ "type": "object" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-redshiftserverless-workgroup.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-redshiftserverless-workgroup.json index 607749193c..8965087931 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-redshiftserverless-workgroup.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-redshiftserverless-workgroup.json @@ -162,7 +162,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 255, "minLength": 0, "pattern": "^sg-[0-9a-fA-F]{8,}$", @@ -252,7 +252,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 255, "minLength": 0, "pattern": "^sg-[0-9a-fA-F]{8,}$", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-route53resolver-resolverendpoint.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-route53resolver-resolverendpoint.json index db6a3d27a5..6d4b6f9e7b 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-route53resolver-resolverendpoint.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-route53resolver-resolverendpoint.json @@ -95,7 +95,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-s3outposts-endpoint.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-s3outposts-endpoint.json index 2edf5ac225..3db3d45d4c 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-s3outposts-endpoint.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-s3outposts-endpoint.json @@ -91,7 +91,7 @@ "type": "string" }, "SecurityGroupId": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 100, "minLength": 1, "pattern": "^sg-([0-9a-f]{8}|[0-9a-f]{17})$", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-cluster.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-cluster.json index d6a9362a45..a9e1561b36 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-cluster.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-cluster.json @@ -296,7 +296,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-dataqualityjobdefinition.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-dataqualityjobdefinition.json index a39902a36c..b6fba22233 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-dataqualityjobdefinition.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-dataqualityjobdefinition.json @@ -465,7 +465,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-domain.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-domain.json index 2f09144e67..6f345dffe5 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-domain.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-domain.json @@ -180,7 +180,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -254,7 +254,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -739,7 +739,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-endpointconfig.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-endpointconfig.json index be6797898e..64c0701640 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-endpointconfig.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-endpointconfig.json @@ -388,7 +388,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-model.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-model.json index 21e6fec7e6..60b9937fe8 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-model.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-model.json @@ -182,7 +182,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-modelbiasjobdefinition.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-modelbiasjobdefinition.json index 88fb94d906..e59104b457 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-modelbiasjobdefinition.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-modelbiasjobdefinition.json @@ -495,7 +495,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-modelexplainabilityjobdefinition.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-modelexplainabilityjobdefinition.json index 75ea571ede..b0f3616e28 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-modelexplainabilityjobdefinition.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-modelexplainabilityjobdefinition.json @@ -455,7 +455,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-modelqualityjobdefinition.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-modelqualityjobdefinition.json index cc8823752f..16876933bc 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-modelqualityjobdefinition.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-modelqualityjobdefinition.json @@ -519,7 +519,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-monitoringschedule.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-monitoringschedule.json index 185ad074d4..dea61efd1b 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-monitoringschedule.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-monitoringschedule.json @@ -601,7 +601,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-notebookinstance.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-notebookinstance.json index bd2c5206c1..a7e6ef0cf6 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-notebookinstance.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-notebookinstance.json @@ -92,7 +92,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-userprofile.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-userprofile.json index bdfd7f6c08..fb08923ef4 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-userprofile.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-sagemaker-userprofile.json @@ -572,7 +572,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-scheduler-schedule.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-scheduler-schedule.json index 553d78ec86..aeb2458ad0 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-scheduler-schedule.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-scheduler-schedule.json @@ -21,7 +21,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 1000, "minLength": 1, "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-synthetics-canary.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-synthetics-canary.json index 88790c5ba1..9172f62f5b 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-synthetics-canary.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-synthetics-canary.json @@ -162,7 +162,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-timestream-influxdbinstance.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-timestream-influxdbinstance.json index 8c4813a249..0ca36fcc35 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-timestream-influxdbinstance.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-timestream-influxdbinstance.json @@ -186,8 +186,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-transfer-server.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-transfer-server.json index 8fcb89e247..668cbbdd22 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-transfer-server.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-transfer-server.json @@ -48,7 +48,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 20, "minLength": 11, "pattern": "sg-[0-9a-f]{8,17}", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-vpclattice-resourcegateway.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-vpclattice-resourcegateway.json index ea8facc81f..994ba3106b 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-vpclattice-resourcegateway.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-vpclattice-resourcegateway.json @@ -63,6 +63,7 @@ "type": "string" }, "SecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { "anyOf": [ @@ -85,6 +86,7 @@ } } ], + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^sg-(([0-9a-z]{8})|([0-9a-z]{17}))$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-vpclattice-servicenetworkvpcassociation.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-vpclattice-servicenetworkvpcassociation.json index 783135d38b..cb927565ad 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-vpclattice-servicenetworkvpcassociation.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-vpclattice-servicenetworkvpcassociation.json @@ -58,7 +58,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 200, "minLength": 0, "pattern": "^sg-(([0-9a-z]{8})|([0-9a-z]{17}))$", diff --git a/src/cfnlint/data/schemas/providers/us_east_1/aws-workspacesweb-networksettings.json b/src/cfnlint/data/schemas/providers/us_east_1/aws-workspacesweb-networksettings.json index e7ec330a82..aaa52066bd 100644 --- a/src/cfnlint/data/schemas/providers/us_east_1/aws-workspacesweb-networksettings.json +++ b/src/cfnlint/data/schemas/providers/us_east_1/aws-workspacesweb-networksettings.json @@ -48,7 +48,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 128, "minLength": 1, "pattern": "^[\\w+\\-]+$", diff --git a/src/cfnlint/data/schemas/providers/us_east_2/aws-codebuild-fleet.json b/src/cfnlint/data/schemas/providers/us_east_2/aws-codebuild-fleet.json index 85c9bd3cbe..05ad47e89e 100644 --- a/src/cfnlint/data/schemas/providers/us_east_2/aws-codebuild-fleet.json +++ b/src/cfnlint/data/schemas/providers/us_east_2/aws-codebuild-fleet.json @@ -136,7 +136,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/us_east_2/aws-m2-environment.json b/src/cfnlint/data/schemas/providers/us_east_2/aws-m2-environment.json index 65f6cde82f..eefe1e876a 100644 --- a/src/cfnlint/data/schemas/providers/us_east_2/aws-m2-environment.json +++ b/src/cfnlint/data/schemas/providers/us_east_2/aws-m2-environment.json @@ -170,7 +170,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^\\S{1,50}$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_east_2/aws-timestream-influxdbinstance.json b/src/cfnlint/data/schemas/providers/us_east_2/aws-timestream-influxdbinstance.json index 3cd225dc53..bfd94ca75f 100644 --- a/src/cfnlint/data/schemas/providers/us_east_2/aws-timestream-influxdbinstance.json +++ b/src/cfnlint/data/schemas/providers/us_east_2/aws-timestream-influxdbinstance.json @@ -191,8 +191,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "maxItems": 5, diff --git a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-apigatewayv2-vpclink.json b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-apigatewayv2-vpclink.json index 6122cf0cee..d29422996a 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-apigatewayv2-vpclink.json +++ b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-apigatewayv2-vpclink.json @@ -17,7 +17,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-autoscaling-launchconfiguration.json b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-autoscaling-launchconfiguration.json index 944f5608ad..fd40ebb2b7 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-autoscaling-launchconfiguration.json +++ b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-autoscaling-launchconfiguration.json @@ -175,7 +175,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-codebuild-project.json b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-codebuild-project.json index 8bb2795ca9..d778c58451 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-codebuild-project.json +++ b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-codebuild-project.json @@ -452,7 +452,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-efs-mounttarget.json b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-efs-mounttarget.json index a6e7d6eb7e..d2a0d168ee 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-efs-mounttarget.json +++ b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-efs-mounttarget.json @@ -23,7 +23,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^sg-[0-9a-f]{8,40}", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-elasticache-serverlesscache.json b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-elasticache-serverlesscache.json index 2ed726ce44..0276511451 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-elasticache-serverlesscache.json +++ b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-elasticache-serverlesscache.json @@ -130,7 +130,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-events-rule.json b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-events-rule.json index 5198fea852..44eeddadfc 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-events-rule.json +++ b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-events-rule.json @@ -18,7 +18,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-fsx-filesystem.json b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-fsx-filesystem.json index 435c672a40..ce06b0b00b 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-fsx-filesystem.json +++ b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-fsx-filesystem.json @@ -400,7 +400,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-m2-environment.json b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-m2-environment.json index 65f6cde82f..eefe1e876a 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-m2-environment.json +++ b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-m2-environment.json @@ -170,7 +170,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^\\S{1,50}$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-opensearchservice-domain.json b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-opensearchservice-domain.json index ddea598f03..80f836bcad 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-opensearchservice-domain.json +++ b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-opensearchservice-domain.json @@ -332,7 +332,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-redshiftserverless-workgroup.json b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-redshiftserverless-workgroup.json index 2a3c4edcd8..3521ac1b10 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-redshiftserverless-workgroup.json +++ b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-redshiftserverless-workgroup.json @@ -138,7 +138,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 255, "minLength": 0, "pattern": "^sg-[0-9a-fA-F]{8,}$", @@ -224,7 +224,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 255, "minLength": 0, "pattern": "^sg-[0-9a-fA-F]{8,}$", diff --git a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-sagemaker-domain.json b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-sagemaker-domain.json index c0a7f8bf5f..b79e2bbd95 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-sagemaker-domain.json +++ b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-sagemaker-domain.json @@ -177,7 +177,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -251,7 +251,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -714,7 +714,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-sagemaker-userprofile.json b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-sagemaker-userprofile.json index b48d981f01..592fbea7ae 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-sagemaker-userprofile.json +++ b/src/cfnlint/data/schemas/providers/us_gov_east_1/aws-sagemaker-userprofile.json @@ -547,7 +547,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-apigatewayv2-vpclink.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-apigatewayv2-vpclink.json index 6122cf0cee..d29422996a 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-apigatewayv2-vpclink.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-apigatewayv2-vpclink.json @@ -17,7 +17,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-appstream-imagebuilder.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-appstream-imagebuilder.json index 1f77bfb4b1..41919ec829 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-appstream-imagebuilder.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-appstream-imagebuilder.json @@ -54,7 +54,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-autoscaling-launchconfiguration.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-autoscaling-launchconfiguration.json index 944f5608ad..fd40ebb2b7 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-autoscaling-launchconfiguration.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-autoscaling-launchconfiguration.json @@ -175,7 +175,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-codebuild-project.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-codebuild-project.json index 8bb2795ca9..d778c58451 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-codebuild-project.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-codebuild-project.json @@ -452,7 +452,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-efs-mounttarget.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-efs-mounttarget.json index a6e7d6eb7e..d2a0d168ee 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-efs-mounttarget.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-efs-mounttarget.json @@ -23,7 +23,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^sg-[0-9a-f]{8,40}", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-events-rule.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-events-rule.json index 5198fea852..44eeddadfc 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-events-rule.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-events-rule.json @@ -18,7 +18,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-fsx-filesystem.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-fsx-filesystem.json index 435c672a40..ce06b0b00b 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-fsx-filesystem.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-fsx-filesystem.json @@ -400,7 +400,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-m2-environment.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-m2-environment.json index 65f6cde82f..eefe1e876a 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-m2-environment.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-m2-environment.json @@ -170,7 +170,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "^\\S{1,50}$", "type": "string" }, diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-opensearchservice-domain.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-opensearchservice-domain.json index ddea598f03..80f836bcad 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-opensearchservice-domain.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-opensearchservice-domain.json @@ -332,7 +332,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-rds-dbproxy.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-rds-dbproxy.json index 70f33290dd..0440d561f6 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-rds-dbproxy.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-rds-dbproxy.json @@ -113,8 +113,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "minItems": 1, diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-rds-dbproxyendpoint.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-rds-dbproxyendpoint.json index ece7dd9078..44602b71ec 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-rds-dbproxyendpoint.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-rds-dbproxyendpoint.json @@ -67,8 +67,10 @@ "type": "string" }, "VpcSecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "minItems": 1, diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-redshiftserverless-workgroup.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-redshiftserverless-workgroup.json index 2a3c4edcd8..3521ac1b10 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-redshiftserverless-workgroup.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-redshiftserverless-workgroup.json @@ -138,7 +138,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 255, "minLength": 0, "pattern": "^sg-[0-9a-fA-F]{8,}$", @@ -224,7 +224,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 255, "minLength": 0, "pattern": "^sg-[0-9a-fA-F]{8,}$", diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-sagemaker-domain.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-sagemaker-domain.json index c0a7f8bf5f..b79e2bbd95 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-sagemaker-domain.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-sagemaker-domain.json @@ -177,7 +177,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -251,7 +251,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" @@ -714,7 +714,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-sagemaker-userprofile.json b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-sagemaker-userprofile.json index b48d981f01..592fbea7ae 100644 --- a/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-sagemaker-userprofile.json +++ b/src/cfnlint/data/schemas/providers/us_gov_west_1/aws-sagemaker-userprofile.json @@ -547,7 +547,7 @@ "SecurityGroups": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 32, "pattern": "[-0-9a-zA-Z]+", "type": "string" diff --git a/src/cfnlint/data/schemas/providers/us_west_1/aws-appstream-fleet.json b/src/cfnlint/data/schemas/providers/us_west_1/aws-appstream-fleet.json index bd742b658a..bbfa163f56 100644 --- a/src/cfnlint/data/schemas/providers/us_west_1/aws-appstream-fleet.json +++ b/src/cfnlint/data/schemas/providers/us_west_1/aws-appstream-fleet.json @@ -67,7 +67,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array", diff --git a/src/cfnlint/data/schemas/providers/us_west_1/aws-cloudformation-typeactivation.json b/src/cfnlint/data/schemas/providers/us_west_1/aws-cloudformation-typeactivation.json index 730262bfac..ff8c82293d 100644 --- a/src/cfnlint/data/schemas/providers/us_west_1/aws-cloudformation-typeactivation.json +++ b/src/cfnlint/data/schemas/providers/us_west_1/aws-cloudformation-typeactivation.json @@ -14,6 +14,7 @@ "additionalProperties": false, "properties": { "LogGroupName": { + "format": "AWS::Logs::LogGroup.Name", "maxLength": 512, "minLength": 1, "pattern": "^[\\.\\-_/#A-Za-z0-9]+$", diff --git a/src/cfnlint/data/schemas/providers/us_west_1/aws-mediaconnect-flow.json b/src/cfnlint/data/schemas/providers/us_west_1/aws-mediaconnect-flow.json index ddfebe3e19..113156efe8 100644 --- a/src/cfnlint/data/schemas/providers/us_west_1/aws-mediaconnect-flow.json +++ b/src/cfnlint/data/schemas/providers/us_west_1/aws-mediaconnect-flow.json @@ -512,7 +512,7 @@ "SecurityGroupIds": { "format": "AWS::EC2::SecurityGroup.Ids", "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "type": "string" }, "type": "array" diff --git a/src/cfnlint/data/schemas/providers/us_west_1/aws-osis-pipeline.json b/src/cfnlint/data/schemas/providers/us_west_1/aws-osis-pipeline.json index 74e53d8db5..fc300c116a 100644 --- a/src/cfnlint/data/schemas/providers/us_west_1/aws-osis-pipeline.json +++ b/src/cfnlint/data/schemas/providers/us_west_1/aws-osis-pipeline.json @@ -95,7 +95,7 @@ "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { - "format": "AWS::EC2::SecurityGroup.GroupId", + "format": "AWS::EC2::SecurityGroup.Id", "maxLength": 20, "minLength": 11, "pattern": "sg-\\w{8}(\\w{9})?", diff --git a/src/cfnlint/data/schemas/providers/us_west_2/aws-pcs-cluster.json b/src/cfnlint/data/schemas/providers/us_west_2/aws-pcs-cluster.json index bd9b718b7d..0eb3ff4219 100644 --- a/src/cfnlint/data/schemas/providers/us_west_2/aws-pcs-cluster.json +++ b/src/cfnlint/data/schemas/providers/us_west_2/aws-pcs-cluster.json @@ -64,6 +64,7 @@ "type": "object" }, "SecurityGroupId": { + "format": "AWS::EC2::SecurityGroup.Id", "pattern": "sg-\\w{8,17}", "type": "string" }, @@ -139,6 +140,7 @@ "additionalProperties": false, "properties": { "SecurityGroupIds": { + "format": "AWS::EC2::SecurityGroup.Ids", "insertionOrder": false, "items": { "$ref": "#/definitions/SecurityGroupId" diff --git a/src/cfnlint/rules/formats/Format.py b/src/cfnlint/rules/formats/Format.py index 538a3f94bd..cfe886b8fb 100644 --- a/src/cfnlint/rules/formats/Format.py +++ b/src/cfnlint/rules/formats/Format.py @@ -34,7 +34,16 @@ def format( if format == rule.format_keyword: # type: ignore if not rule.format(validator, instance): # type: ignore + if hasattr(rule, "pattern"): + yield ValidationError( + ( + f"{instance!r} is not a {format!r} with " + f"pattern {rule.pattern!r}" + ), + rule=rule, + ) + continue yield ValidationError( - f"{instance!r} is not a {format!r}", + f"{instance!r} is not a valid {format!r}", rule=rule, ) diff --git a/src/cfnlint/rules/formats/FormatKeyword.py b/src/cfnlint/rules/formats/FormatKeyword.py index 93817173f9..1368b27ab3 100644 --- a/src/cfnlint/rules/formats/FormatKeyword.py +++ b/src/cfnlint/rules/formats/FormatKeyword.py @@ -5,12 +5,27 @@ from __future__ import annotations +from typing import Any + +import regex as re + +from cfnlint.jsonschema import Validator from cfnlint.rules import CloudFormationLintRule class FormatKeyword(CloudFormationLintRule): - def __init__(self, format: str | None = None) -> None: + def __init__(self, format: str | None = None, pattern: str | None = None) -> None: super().__init__() self.format_keyword = format self.parent_rules = ["E1103"] + self.pattern = pattern or r"" + + def format(self, validator: Validator, instance: Any) -> bool: + if not isinstance(instance, str): + return True + + if re.match(self.pattern, instance): + return True + + return False diff --git a/src/cfnlint/rules/formats/LogGroupName.py b/src/cfnlint/rules/formats/LogGroupName.py new file mode 100644 index 0000000000..d07fdfc357 --- /dev/null +++ b/src/cfnlint/rules/formats/LogGroupName.py @@ -0,0 +1,21 @@ +""" +Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +SPDX-License-Identifier: MIT-0 +""" + +from __future__ import annotations + +from cfnlint.rules.formats.FormatKeyword import FormatKeyword + + +class LogGroupName(FormatKeyword): + id = "E1155" + shortdesc = "Validate CloudWatch logs group name" + description = "Check that a CloudWatch log group name matches a pattern" + tags = [] + source_url = "https://github.com/aws-cloudformation/cfn-lint/blob/main/docs/format_keyword.md#AWS::Logs::LogGroup.Name" + + def __init__(self): + super().__init__( + format="AWS::EC2::Subnet.Id", pattern=r"^[\.\-_\/#A-Za-z0-9]{1,512}\Z" + ) diff --git a/src/cfnlint/rules/formats/SecurityGroupId.py b/src/cfnlint/rules/formats/SecurityGroupId.py index 3fcba0d203..aee970b9ff 100644 --- a/src/cfnlint/rules/formats/SecurityGroupId.py +++ b/src/cfnlint/rules/formats/SecurityGroupId.py @@ -5,11 +5,6 @@ from __future__ import annotations -from typing import Any - -import regex as re - -from cfnlint.jsonschema import Validator from cfnlint.rules.formats.FormatKeyword import FormatKeyword @@ -21,16 +16,10 @@ class SecurityGroupId(FormatKeyword): "group or has the valid pattern" ) tags = [] - source_url = "https://github.com/aws-cloudformation/cfn-lint/blob/main/docs/format_keyword.md#AWS::EC2::SecurityGroup.GroupId" + source_url = "https://github.com/aws-cloudformation/cfn-lint/blob/main/docs/format_keyword.md#AWS::EC2::SecurityGroup.Id" def __init__(self): - super().__init__(format="AWS::EC2::SecurityGroup.GroupId") - - def format(self, validator: Validator, instance: Any) -> bool: - if not isinstance(instance, str): - return True - - if re.match(r"^sg-([a-fA-F0-9]{8}|[a-fA-F0-9]{17})$", instance): - return True - - return False + super().__init__( + format="AWS::EC2::SecurityGroup.Id", + pattern=r"^sg-([a-fA-F0-9]{8}|[a-fA-F0-9]{17})$", + ) diff --git a/src/cfnlint/rules/formats/SecurityGroupName.py b/src/cfnlint/rules/formats/SecurityGroupName.py index bd7685f16b..f121430f7e 100644 --- a/src/cfnlint/rules/formats/SecurityGroupName.py +++ b/src/cfnlint/rules/formats/SecurityGroupName.py @@ -5,11 +5,6 @@ from __future__ import annotations -from typing import Any - -import regex as re - -from cfnlint.jsonschema import Validator from cfnlint.rules.formats.FormatKeyword import FormatKeyword @@ -18,16 +13,10 @@ class SecurityGroupName(FormatKeyword): shortdesc = "Validate security group name" description = "Security group names have to valid pattern" tags = [] - source_url = "https://github.com/aws-cloudformation/cfn-lint/blob/main/docs/format_keyword.md#AWS::EC2::SecurityGroup.GroupName" + source_url = "https://github.com/aws-cloudformation/cfn-lint/blob/main/docs/format_keyword.md#AWS::EC2::SecurityGroup.Name" def __init__(self): - super().__init__(format="AWS::EC2::SecurityGroup.GroupName") - - def format(self, validator: Validator, instance: Any) -> bool: - if not isinstance(instance, str): - return True - - if re.match(r"^[a-zA-Z0-9 \._\-:\/()#\,@\[\]+=&;\{\}!\$\*]+$", instance): - return True - - return False + super().__init__( + format="AWS::EC2::SecurityGroup.Name", + pattern=r"^[a-zA-Z0-9 \._\-:\/()#\,@\[\]+=&;\{\}!\$\*]+$", + ) diff --git a/src/cfnlint/rules/formats/SubnetId.py b/src/cfnlint/rules/formats/SubnetId.py index f4e5311cf2..552c088dd8 100644 --- a/src/cfnlint/rules/formats/SubnetId.py +++ b/src/cfnlint/rules/formats/SubnetId.py @@ -5,11 +5,6 @@ from __future__ import annotations -from typing import Any - -import regex as re - -from cfnlint.jsonschema import Validator from cfnlint.rules.formats.FormatKeyword import FormatKeyword @@ -21,13 +16,7 @@ class SubnetId(FormatKeyword): source_url = "https://github.com/aws-cloudformation/cfn-lint/blob/main/docs/format_keyword.md#AWS::EC2::Subnet.Id" def __init__(self): - super().__init__(format="AWS::EC2::Subnet.Id") - - def format(self, validator: Validator, instance: Any) -> bool: - if not isinstance(instance, str): - return True - - if re.match(r"^subnet-(([0-9A-Fa-f]{8})|([0-9A-Fa-f]{17}))$", instance): - return True - - return False + super().__init__( + format="AWS::EC2::Subnet.Id", + pattern=r"^subnet-(([0-9A-Fa-f]{8})|([0-9A-Fa-f]{17}))$", + ) diff --git a/src/cfnlint/rules/formats/VpcId.py b/src/cfnlint/rules/formats/VpcId.py index 1c6657b480..100b5c9cae 100644 --- a/src/cfnlint/rules/formats/VpcId.py +++ b/src/cfnlint/rules/formats/VpcId.py @@ -5,11 +5,6 @@ from __future__ import annotations -from typing import Any - -import regex as re - -from cfnlint.jsonschema import Validator from cfnlint.rules.formats.FormatKeyword import FormatKeyword @@ -21,13 +16,7 @@ class VpcId(FormatKeyword): source_url = "https://github.com/aws-cloudformation/cfn-lint/blob/main/docs/format_keyword.md#AWS::EC2::VPC.Id" def __init__(self): - super().__init__(format="AWS::EC2::VPC.Id") - - def format(self, validator: Validator, instance: Any) -> bool: - if not isinstance(instance, str): - return True - - if re.match(r"^vpc-(([0-9A-Fa-f]{8})|([0-9A-Fa-f]{17}))$", instance): - return True - - return False + super().__init__( + format="AWS::EC2::VPC.Id", + pattern=r"^vpc-(([0-9A-Fa-f]{8})|([0-9A-Fa-f]{17}))$", + ) diff --git a/src/cfnlint/rules/formats/_schema_comparer.py b/src/cfnlint/rules/formats/_schema_comparer.py new file mode 100644 index 0000000000..bfec40cc06 --- /dev/null +++ b/src/cfnlint/rules/formats/_schema_comparer.py @@ -0,0 +1,112 @@ +""" +Helpers for loading resources, managing specs, constants, etc. + +Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +SPDX-License-Identifier: MIT-0 +""" + +from __future__ import annotations + +from typing import Any, Callable + +from cfnlint.jsonschema.exceptions import ValidationError + +_keyword = "format" + + +def _any_of( + source: str, + any_ofs: list[dict[str, Any]], +) -> tuple[bool, list[str]]: + """Compare the source schema with the destination schema and + return a ValidationError if they don't match. + + Args: + source (str): The source schema to compare. + destination (list[dict[str, Any]]): The anyOf schemas + + Returns: + tuple[bool, list[str]]: A bool value if format matches and a + list of format values if they don't match. + """ + formats = [] + for subschema in any_ofs: + if _keyword in subschema: + if source == subschema[_keyword]: + return True, [] + + formats.append(subschema[_keyword]) + + return False, formats + + +_schema_composition: dict[str, Callable] = { + "anyOf": _any_of, +} + + +def _compare_schemas( + source: str, + destination: dict[str, Any], +) -> tuple[bool, list[str]]: + """Compare two schemas and return a ValidationError if they don't match. + + Args: + source (str): The source schema to compare. + destination (dict[str, Any]): The destination schema to compare against. + + Returns: + tuple[bool, list[str]]: True/False if the format keyword matches + """ + + dest_f = destination.get(_keyword) + if dest_f == source: + return True, [dest_f] # Nothing else matters to be on the safe side + + all_formats = [dest_f] if dest_f else [] + for composition_key in _schema_composition: + if composition_key in destination: + match, formats = _schema_composition[composition_key]( + source, destination[composition_key] + ) + if match: + return True, [] + all_formats.extend(formats) + + return False, all_formats + + +def compare_schemas( + source: dict[str, Any], + destination: dict[str, Any], +) -> ValidationError | None: + """Compare two schemas and return a ValidationError if they don't match. + + Args: + source (dict[str, Any]): The source schema to compare. + destination (dict[str, Any]): The destination schema to compare against. + + Returns: + ValidationError: A ValidationError if the schemas don't match, otherwise None. + """ + + f = source.get(_keyword) + if f is None: + return None + + match, formats = _compare_schemas(f, destination) + if match: + return None + + if formats: + return ValidationError( + f"{f!r} format is incompatible with formats {formats!r}", + schema={"format": f}, + instance=formats, + ) + + return ValidationError( + f"{f!r} format is incompatible", + schema={"format": f}, + instance=None, + ) diff --git a/src/cfnlint/rules/functions/GetAttFormat.py b/src/cfnlint/rules/functions/GetAttFormat.py index 91f5c1808a..002582fa36 100644 --- a/src/cfnlint/rules/functions/GetAttFormat.py +++ b/src/cfnlint/rules/functions/GetAttFormat.py @@ -17,7 +17,7 @@ class GetAttFormat(CfnLintKeyword): "Validate that if source and destination format exists that they match" ) source_url = "https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/best-practices.html#parmtypes" - tags = ["parameters", "ec2", "imageid"] + tags = ["functions", "getatt"] def __init__(self): super().__init__(["*"]) @@ -64,7 +64,20 @@ def validate( getatt_schema = resource_schema.resolver.resolve_cfn_pointer(getatt_ptr) getatt_fmt = getatt_schema.get("format") if getatt_fmt != fmt: - yield ValidationError( - f"{{'Fn::GetAtt': {instance!r}}} that does not match {fmt!r}", - rule=self, - ) + if getatt_fmt is None: + yield ValidationError( + ( + f"{{'Fn::GetAtt': {instance!r}}} does not match " + f"destination format of {fmt!r}" + ), + rule=self, + ) + else: + yield ValidationError( + ( + f"{{'Fn::GetAtt': {instance!r}}} with format " + f"{getatt_fmt!r} does not " + f"match destination format of {fmt!r}" + ), + rule=self, + ) diff --git a/src/cfnlint/rules/functions/Ref.py b/src/cfnlint/rules/functions/Ref.py index 6f0221d4f8..5b2109f6c7 100644 --- a/src/cfnlint/rules/functions/Ref.py +++ b/src/cfnlint/rules/functions/Ref.py @@ -63,32 +63,33 @@ def ref(self, validator, subschema, instance, schema): if not validator.is_type(value, "string"): return - if value not in validator.context.parameters: - return - - parameter_type = validator.context.parameters[value].type - schema_types = self.resolve_type(validator, subschema) - if not schema_types: - return - reprs = ", ".join(repr(type) for type in schema_types) - - if all( - st not in ["string", "boolean", "integer", "number"] for st in schema_types - ): - if parameter_type not in VALID_PARAMETER_TYPES_LIST: - yield ValidationError(f"{instance!r} is not of type {reprs}") - return - elif all(st not in ["array"] for st in schema_types): - if parameter_type not in [ - x for x in VALID_PARAMETER_TYPES if x not in VALID_PARAMETER_TYPES_LIST - ]: - yield ValidationError(f"{instance!r} is not of type {reprs}") + if value in validator.context.parameters: + parameter_type = validator.context.parameters[value].type + schema_types = self.resolve_type(validator, subschema) + if not schema_types: return + reprs = ", ".join(repr(type) for type in schema_types) + + if all( + st not in ["string", "boolean", "integer", "number"] + for st in schema_types + ): + if parameter_type not in VALID_PARAMETER_TYPES_LIST: + yield ValidationError(f"{instance!r} is not of type {reprs}") + return + elif all(st not in ["array"] for st in schema_types): + if parameter_type not in [ + x + for x in VALID_PARAMETER_TYPES + if x not in VALID_PARAMETER_TYPES_LIST + ]: + yield ValidationError(f"{instance!r} is not of type {reprs}") + return for rule_id in self._all_refs: rule = self.child_rules.get(rule_id) if rule: - yield from rule.validate(validator, {}, instance, schema) + yield from rule.validate(validator, {}, value, subschema) keyword = validator.context.path.cfn_path_string for rule in self.child_rules.values(): @@ -96,5 +97,5 @@ def ref(self, validator, subschema, instance, schema): continue if not hasattr(rule, "keywords"): continue - if keyword in rule.keywords: - yield from rule.validate(validator, keyword, instance, schema) + if keyword in rule.keywords or "*" in rule.keywords: + yield from rule.validate(validator, keyword, value, subschema) diff --git a/src/cfnlint/rules/functions/RefFormat.py b/src/cfnlint/rules/functions/RefFormat.py new file mode 100644 index 0000000000..c734e6403a --- /dev/null +++ b/src/cfnlint/rules/functions/RefFormat.py @@ -0,0 +1,94 @@ +""" +Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +SPDX-License-Identifier: MIT-0 +""" + +from __future__ import annotations + +from copy import deepcopy +from typing import Any + +from cfnlint.jsonschema import ValidationResult, Validator +from cfnlint.jsonschema._utils import Unset +from cfnlint.rules.formats._schema_comparer import compare_schemas +from cfnlint.rules.jsonschema import CfnLintKeyword +from cfnlint.schema import PROVIDER_SCHEMA_MANAGER + + +class RefFormat(CfnLintKeyword): + id = "E1041" + shortdesc = "Check if Ref matches destination format" + description = ( + "When source and destination format exists validate that they match in a Ref" + ) + source_url = "https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/best-practices.html#parmtypes" + tags = ["functions", "ref"] + + def __init__(self): + super().__init__(["*"]) + self.parent_rules = ["E1020"] + + def _filter_schema( + self, validator: Validator, type_name: str, id: str, schema: dict[str, Any] + ) -> dict[str, Any]: + if type_name != "AWS::EC2::SecurityGroup": + return schema + + items = list( + validator.cfn.get_cfn_path( + ["Resources", id, "Properties", "VpcId"], validator.context + ) + ) + if items: + # VpcId is specified and will have a value which means the returned value is + # "AWS::EC2::SecurityGroup.Id" + schema = deepcopy(schema) + schema.pop("anyOf") + schema["format"] = "AWS::EC2::SecurityGroup.Id" + return schema + + # VpcId being None means it wasn't specified and the value is a Name + schema = deepcopy(schema) + schema.pop("anyOf") + schema["format"] = "AWS::EC2::SecurityGroup.Name" + return schema + + def validate( + self, validator: Validator, _, instance: Any, schema: Any + ) -> ValidationResult: + if instance in validator.context.parameters: + return + + if instance not in validator.context.resources: + return + t = validator.context.resources[instance].type + for ( + regions, + resource_schema, + ) in PROVIDER_SCHEMA_MANAGER.get_resource_schemas_by_regions( + t, validator.context.regions + ): + region = regions[0] + + ref_schema = validator.context.resources[instance].ref(region) + + ref_schema = self._filter_schema(validator, t, instance, ref_schema) + + err = compare_schemas(schema, ref_schema) + if err: + if err.instance: + err.message = ( + f"{{'Ref': {instance!r}}} with formats {err.instance!r} " + "does not match destination format of " + f"{err.schema.get('format')!r}" + ) + else: + err.message = ( + f"{{'Ref': {instance!r}}} does not match " + f"destination format of {err.schema.get('format')!r}" + ) + + err.instance = Unset() + err.schema = Unset() + err.rule = self + yield err diff --git a/src/cfnlint/rules/parameters/DynamicReferenceSecret.py b/src/cfnlint/rules/parameters/DynamicReferenceSecret.py index 1bcd4924bc..e94878b208 100644 --- a/src/cfnlint/rules/parameters/DynamicReferenceSecret.py +++ b/src/cfnlint/rules/parameters/DynamicReferenceSecret.py @@ -48,12 +48,11 @@ def validate(self, validator: Validator, _, instance: Any, schema: Any): functions = set(FUNCTIONS) - set(["Fn::If"]) if any(p in functions for p in validator.context.path.path): return - value = instance.get("Ref") - if not validator.is_type(value, "string"): + if not validator.is_type(instance, "string"): return - if value in validator.context.parameters: + if instance in validator.context.parameters: yield ValidationError( "Use dynamic references over parameters for secrets", rule=self ) diff --git a/src/cfnlint/rules/parameters/NoEcho.py b/src/cfnlint/rules/parameters/NoEcho.py index dcd26b2004..c98eb9afe1 100644 --- a/src/cfnlint/rules/parameters/NoEcho.py +++ b/src/cfnlint/rules/parameters/NoEcho.py @@ -21,12 +21,10 @@ class NoEcho(CloudFormationLintRule): tags = ["functions", "dynamic reference", "ref"] def validate(self, validator: Validator, _, instance: Any, schema: Any): - value = instance.get("Ref") - - if not validator.is_type(value, "string"): + if not validator.is_type(instance, "string"): return - parameter = validator.context.parameters.get(value) + parameter = validator.context.parameters.get(instance) if not parameter: return @@ -37,7 +35,10 @@ def validate(self, validator: Validator, _, instance: Any, schema: Any): and validator.context.path.path[2] == "Metadata" ): yield ValidationError( - f"Don't use 'NoEcho' parameter {value!r} in resource metadata", + ( + f"Don't use 'NoEcho' parameter {instance!r} " + "in resource metadata" + ), rule=self, path=deque(["Ref"]), ) @@ -46,7 +47,7 @@ def validate(self, validator: Validator, _, instance: Any, schema: Any): if validator.context.path.path[0] in ["Metadata", "Outputs"]: yield ValidationError( ( - f"Don't use 'NoEcho' parameter {value!r} " + f"Don't use 'NoEcho' parameter {instance!r} " f"in {validator.context.path.path[0]!r}" ), rule=self, diff --git a/src/cfnlint/rules/resources/ecs/LogConfiguration.py b/src/cfnlint/rules/resources/ecs/LogConfiguration.py index 0f675cb47c..97fa9f5a90 100644 --- a/src/cfnlint/rules/resources/ecs/LogConfiguration.py +++ b/src/cfnlint/rules/resources/ecs/LogConfiguration.py @@ -5,9 +5,10 @@ from __future__ import annotations -from typing import Sequence +from typing import Any, Sequence import cfnlint.data.schemas.extensions.aws_ecs_taskdefinition +from cfnlint.jsonschema import ValidationResult, Validator from cfnlint.rules.jsonschema.CfnLintJsonSchema import CfnLintJsonSchema, SchemaDetails @@ -32,3 +33,24 @@ def __init__( ), all_matches=True, ) + + def validate( + self, validator: Validator, keywords: Any, instance: Any, schema: dict[str, Any] + ) -> ValidationResult: + # if the schema has a description will only replace the message with that + # description and use the best error for the location information + if not self._use_schema_arg: + schema = self._schema + + cfn_validator = self.extend_validator( + validator=validator.evolve( + function_filter=validator.function_filter.evolve( + validate_dynamic_references=False, + add_cfn_lint_keyword=False, + ) + ), + schema=schema, + context=validator.context.evolve(), + ) + + yield from self._iter_errors(cfn_validator, instance) diff --git a/src/cfnlint/rules/resources/properties/ImageId.py b/src/cfnlint/rules/resources/properties/ImageId.py index 6780ccaa20..6bf7083f27 100644 --- a/src/cfnlint/rules/resources/properties/ImageId.py +++ b/src/cfnlint/rules/resources/properties/ImageId.py @@ -40,11 +40,10 @@ def validate(self, validator: Validator, _, instance: Any, schema: Any): if any(fn in validator.context.path.path for fn in FUNCTIONS): return - value = instance.get("Ref") - if value not in validator.context.parameters: + if instance not in validator.context.parameters: return - parameter_type = validator.context.parameters[value].type + parameter_type = validator.context.parameters[instance].type for err in validator.descend( instance=parameter_type, schema={ @@ -55,5 +54,5 @@ def validate(self, validator: Validator, _, instance: Any, schema: Any): }, ): err.rule = self - err.path_override = deque(["Parameters", value, "Type"]) + err.path_override = deque(["Parameters", instance, "Type"]) yield err diff --git a/src/cfnlint/schema/_ref.py b/src/cfnlint/schema/_ref.py new file mode 100644 index 0000000000..7861c27a1f --- /dev/null +++ b/src/cfnlint/schema/_ref.py @@ -0,0 +1,26 @@ +""" +Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +SPDX-License-Identifier: MIT-0 +""" + +from __future__ import annotations + +from typing import TYPE_CHECKING, Any + +if TYPE_CHECKING: + from cfnlint.schema import Schema + + +class Ref: + + def __init__(self, schema: "Schema") -> None: + primary_ids = schema.schema.get("primaryIdentifier", []) + if len(primary_ids) > 1: + self._ref = {"type": "string"} + else: + for primary_id in primary_ids: + self._ref = schema.resolver.resolve_cfn_pointer(primary_id) + + @property + def ref(self) -> dict[str, Any]: + return self._ref diff --git a/src/cfnlint/schema/_schema.py b/src/cfnlint/schema/_schema.py index ba38e51d64..113a4bd9d8 100644 --- a/src/cfnlint/schema/_schema.py +++ b/src/cfnlint/schema/_schema.py @@ -10,6 +10,7 @@ import jsonpatch from cfnlint.schema._getatts import AttributeDict, GetAtts +from cfnlint.schema._ref import Ref from cfnlint.schema.resolver import RefResolver # Can't use a dataclass because its hard to parse in json @@ -23,6 +24,7 @@ def __init__(self, schema: dict[str, Any], is_cached: bool = False) -> None: self._type_name: str = schema["typeName"] self.resolver: RefResolver = RefResolver.from_schema(schema) self._getatts: GetAtts = GetAtts(self) + self._ref: Ref = Ref(self) @property def type_name(self) -> str: @@ -60,3 +62,7 @@ def get_atts(self) -> AttributeDict: object for the property """ return self._getatts.attrs + + @property + def ref(self) -> dict[str, Any]: + return self._ref.ref diff --git a/src/cfnlint/schema/manager.py b/src/cfnlint/schema/manager.py index 6bad1161af..2aa6bf3191 100644 --- a/src/cfnlint/schema/manager.py +++ b/src/cfnlint/schema/manager.py @@ -578,5 +578,20 @@ def get_type_getatts(self, resource_type: str, region: str) -> AttributeDict: self.get_resource_schema(region=region, resource_type=resource_type) return self._schemas[region][resource_type].get_atts + @lru_cache(maxsize=None) + def get_type_ref(self, resource_type: str, region: str) -> dict[str, Any]: + """Get the Ref information for a type in a region + + Args: + resource_type: The type of the resource. Example: AWS::S3::Bucket + region: The region to load the resource type from + Returns: + dict(str, Any): Returns a Dict where the keys are the attributes and the + value is the CloudFormation schema description of the attribute + """ + resource_type = self._normalize_resource_type(resource_type) + self.get_resource_schema(region=region, resource_type=resource_type) + return self._schemas[region][resource_type].ref + PROVIDER_SCHEMA_MANAGER: ProviderSchemaManager = ProviderSchemaManager() diff --git a/src/cfnlint/template/template.py b/src/cfnlint/template/template.py index e7a02fe056..145d1ec4d6 100644 --- a/src/cfnlint/template/template.py +++ b/src/cfnlint/template/template.py @@ -15,7 +15,8 @@ import cfnlint.conditions import cfnlint.helpers from cfnlint._typing import CheckValueFn, Path -from cfnlint.context import create_context_for_template +from cfnlint.context import Context, create_context_for_template +from cfnlint.context.conditions.exceptions import Unsatisfiable from cfnlint.decode.node import dict_node, list_node from cfnlint.graph import Graph from cfnlint.match import Match @@ -431,6 +432,83 @@ def search_deep_keys( results.append(["Globals"] + pre_result) return results + def get_cfn_path( + self, path: list[str], context: Context + ) -> Iterator[tuple[Any, Context]]: + """ + Get the value at the specified path in the CloudFormation template. + + Args: + path (list[str]): The path to the value in the template. + context (Context): The context object containing the template and other data. + + Returns: + Any: The value at the specified path in the template. + """ + + def _filter_condition( + template: Any, context: Context + ) -> Iterator[tuple[Any, Context]]: + k, v = cfnlint.helpers.is_function(template) + if k is None: + yield template, context + return + + if k == "Fn::If": + if isinstance(v, list) and len(v) == 3: + condition = v[0] + if not isinstance(condition, str): + return + + for i in [1, 2]: + b = True if i == 1 else False + try: + item_context = context.evolve( + conditions=context.conditions.evolve({condition: b}) + ) + yield from _filter_condition(v[i], item_context) + except Unsatisfiable: + continue + return + if k == "Ref": + if v == "AWS::NoValue": + return + yield template, context + + def _get_cfn_path( + path: list[str], template: Any, context: Context + ) -> Iterator[tuple[Any, Context]]: + if len(path) == 0: + yield from _filter_condition(template, context) + return + item = path[0] + if isinstance(template, dict): + if item in template: + for item_template, item_context in _filter_condition( + template[item], context + ): + yield from _get_cfn_path(path[1:], item_template, item_context) + return + elif isinstance(template, list): + if isinstance(template, list): + if item == "*": + for index, _ in enumerate(template): + yield from _get_cfn_path(path[1:], template[index], context) + return + + # handle resource and output conditions + if len(path) >= 3 and path[0] in ["Resources", "Outputs"]: + condition = self.template.get(path[0], {}).get(path[1], {}).get("Condition") + if condition: + try: + context = context.evolve( + conditions=context.conditions.evolve({condition: True}) + ) + except Unsatisfiable: + return + + yield from _get_cfn_path(path, self.template, context) + def get_condition_values(self, template, path: Path | None) -> list[dict[str, Any]]: """ Evaluates conditions in the provided CloudFormation template and returns the values. diff --git a/test/fixtures/results/integration/formats.json b/test/fixtures/results/integration/formats.json new file mode 100644 index 0000000000..bd700aae0b --- /dev/null +++ b/test/fixtures/results/integration/formats.json @@ -0,0 +1,66 @@ +[ + { + "Filename": "test/fixtures/templates/integration/formats.yaml", + "Id": "0030de3f-c28c-0148-a503-13e3a6130c1e", + "Level": "Error", + "Location": { + "End": { + "ColumnNumber": 19, + "LineNumber": 40 + }, + "Path": [ + "Resources", + "Instance1", + "Properties", + "NetworkInterfaces", + 1, + "GroupSet", + 3 + ], + "Start": { + "ColumnNumber": 13, + "LineNumber": 40 + } + }, + "Message": "'sg-dne' is not a 'AWS::EC2::SecurityGroup.Id' with pattern '^sg-([a-fA-F0-9]{8}|[a-fA-F0-9]{17})$'", + "ParentId": null, + "Rule": { + "Description": "Security groups have to ref/gettatt to a security group or has the valid pattern", + "Id": "E1150", + "ShortDescription": "Validate security group format", + "Source": "https://github.com/aws-cloudformation/cfn-lint/blob/main/docs/format_keyword.md#AWS::EC2::SecurityGroup.Id" + } + }, + { + "Filename": "test/fixtures/templates/integration/formats.yaml", + "Id": "f76fa81f-837e-7502-0be7-3d8ff34024e1", + "Level": "Error", + "Location": { + "End": { + "ColumnNumber": 44, + "LineNumber": 44 + }, + "Path": [ + "Resources", + "Instance1", + "Properties", + "NetworkInterfaces", + 2, + "GroupSet", + 0 + ], + "Start": { + "ColumnNumber": 13, + "LineNumber": 44 + } + }, + "Message": "{'Fn::GetAtt': ['SecurityGroup', 'GroupName']} with format 'AWS::EC2::SecurityGroup.Name' does not match destination format of 'AWS::EC2::SecurityGroup.Id'", + "ParentId": null, + "Rule": { + "Description": "Validate that if source and destination format exists that they match", + "Id": "E1040", + "ShortDescription": "Check if GetAtt matches destination format", + "Source": "https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/best-practices.html#parmtypes" + } + } +] diff --git a/test/fixtures/results/integration/getatt-types.json b/test/fixtures/results/integration/getatt-types.json index 2d15e311cd..e9fd274dc9 100644 --- a/test/fixtures/results/integration/getatt-types.json +++ b/test/fixtures/results/integration/getatt-types.json @@ -31,12 +31,45 @@ }, { "Filename": "test/fixtures/templates/integration/getatt-types.yaml", - "Id": "f9f8618f-c9a0-d78f-84f6-a2fb809cc514", + "Id": "16620b40-6f3e-69eb-874f-34b5f51cedee", + "Level": "Error", + "Location": { + "End": { + "ColumnNumber": 28, + "LineNumber": 62 + }, + "Path": [ + "Resources", + "TestTaskDefinitionWithGetAtt", + "Properties", + "ContainerDefinitions", + 0, + "LogConfiguration", + "Options", + "awslogs-group" + ], + "Start": { + "ColumnNumber": 15, + "LineNumber": 62 + } + }, + "Message": "{'Fn::GetAtt': ['TestLogGroup', 'Arn']} does not match destination format of 'AWS::Logs::LogGroup.Name'", + "ParentId": null, + "Rule": { + "Description": "Validate that if source and destination format exists that they match", + "Id": "E1040", + "ShortDescription": "Check if GetAtt matches destination format", + "Source": "https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/best-practices.html#parmtypes" + } + }, + { + "Filename": "test/fixtures/templates/integration/getatt-types.yaml", + "Id": "536e9277-ad5b-fed7-821e-34fb182c3ecc", "Level": "Error", "Location": { "End": { "ColumnNumber": 69, - "LineNumber": 35 + "LineNumber": 85 }, "Path": [ "Outputs", @@ -49,7 +82,7 @@ ], "Start": { "ColumnNumber": 57, - "LineNumber": 35 + "LineNumber": 85 } }, "Message": "{'Fn::GetAtt': ['CapacityReservation', 'InstanceCount']} is not of type 'string'", @@ -63,12 +96,12 @@ }, { "Filename": "test/fixtures/templates/integration/getatt-types.yaml", - "Id": "518fa518-bd82-b365-8ec2-c48ae8581f3e", + "Id": "36c89a62-589a-e0db-d49b-3dae6791806c", "Level": "Error", "Location": { "End": { "ColumnNumber": 10, - "LineNumber": 37 + "LineNumber": 87 }, "Path": [ "Outputs", @@ -78,7 +111,7 @@ ], "Start": { "ColumnNumber": 5, - "LineNumber": 37 + "LineNumber": 87 } }, "Message": "{'Fn::GetAtt': ['CapacityReservation', 'InstanceCount']} is not of type 'string'", @@ -92,12 +125,12 @@ }, { "Filename": "test/fixtures/templates/integration/getatt-types.yaml", - "Id": "3ff33f0b-1651-bc3b-710e-e603779c3c5f", + "Id": "d66d8ee3-bb6c-8635-52ea-622393dd61b0", "Level": "Error", "Location": { "End": { "ColumnNumber": 10, - "LineNumber": 39 + "LineNumber": 89 }, "Path": [ "Outputs", @@ -107,7 +140,7 @@ ], "Start": { "ColumnNumber": 5, - "LineNumber": 39 + "LineNumber": 89 } }, "Message": "'CapacityReservation.InstanceCount' is not of type 'string'", @@ -121,12 +154,12 @@ }, { "Filename": "test/fixtures/templates/integration/getatt-types.yaml", - "Id": "c9b79105-67dc-dbe7-3757-b4a9d47c5366", + "Id": "e188f184-e315-36dc-231e-6cfd557932bf", "Level": "Informational", "Location": { "End": { "ColumnNumber": 22, - "LineNumber": 41 + "LineNumber": 91 }, "Path": [ "Outputs", @@ -137,7 +170,7 @@ ], "Start": { "ColumnNumber": 20, - "LineNumber": 41 + "LineNumber": 91 } }, "Message": "Prefer using Fn::Sub over Fn::Join with an empty delimiter", @@ -151,12 +184,12 @@ }, { "Filename": "test/fixtures/templates/integration/getatt-types.yaml", - "Id": "e9db8f22-319e-6556-6eef-9dfb16e9aa1b", + "Id": "78f2b914-89f3-f2a3-7013-d8d2d3dc3439", "Level": "Error", "Location": { "End": { "ColumnNumber": 10, - "LineNumber": 43 + "LineNumber": 93 }, "Path": [ "Outputs", @@ -169,7 +202,7 @@ ], "Start": { "ColumnNumber": 5, - "LineNumber": 43 + "LineNumber": 93 } }, "Message": "{'Fn::GetAtt': ['CapacityReservation', 'InstanceCount']} is not of type 'string'", @@ -183,12 +216,12 @@ }, { "Filename": "test/fixtures/templates/integration/getatt-types.yaml", - "Id": "a777b7aa-5a61-f44b-0e11-7f8fad0117c0", + "Id": "fb048506-abb7-1e8f-b3c4-16b5f8c63cae", "Level": "Informational", "Location": { "End": { "ColumnNumber": 22, - "LineNumber": 43 + "LineNumber": 93 }, "Path": [ "Outputs", @@ -199,7 +232,7 @@ ], "Start": { "ColumnNumber": 20, - "LineNumber": 43 + "LineNumber": 93 } }, "Message": "Prefer using Fn::Sub over Fn::Join with an empty delimiter", @@ -213,12 +246,12 @@ }, { "Filename": "test/fixtures/templates/integration/getatt-types.yaml", - "Id": "f968510f-4410-ab60-e14d-76661faf7d3e", + "Id": "37606842-eb43-dd6c-36a2-d69c367b389d", "Level": "Error", "Location": { "End": { "ColumnNumber": 10, - "LineNumber": 47 + "LineNumber": 97 }, "Path": [ "Outputs", @@ -228,7 +261,7 @@ ], "Start": { "ColumnNumber": 5, - "LineNumber": 47 + "LineNumber": 97 } }, "Message": "{'Fn::GetAtt': ['CapacityReservation', 'EphemeralStorage']} is not of type 'string'", diff --git a/test/fixtures/results/integration/ref-types.json b/test/fixtures/results/integration/ref-types.json new file mode 100644 index 0000000000..f440d37f6d --- /dev/null +++ b/test/fixtures/results/integration/ref-types.json @@ -0,0 +1,31 @@ +[ + { + "Filename": "test/fixtures/templates/integration/ref-types.yaml", + "Id": "2f03486c-dde0-ea5e-49a6-634f3a935841", + "Level": "Error", + "Location": { + "End": { + "ColumnNumber": 12, + "LineNumber": 45 + }, + "Path": [ + "Resources", + "Subnet2", + "Properties", + "VpcId" + ], + "Start": { + "ColumnNumber": 7, + "LineNumber": 45 + } + }, + "Message": "{'Ref': 'FargateTaskRole'} does not match destination format of 'AWS::EC2::VPC.Id'", + "ParentId": null, + "Rule": { + "Description": "When source and destination format exists validate that they match in a Ref", + "Id": "E1041", + "ShortDescription": "Check if Ref matches destination format", + "Source": "https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/best-practices.html#parmtypes" + } + } +] diff --git a/test/fixtures/results/quickstart/nist_application.json b/test/fixtures/results/quickstart/nist_application.json index f291af9372..c7b5a4e5d7 100644 --- a/test/fixtures/results/quickstart/nist_application.json +++ b/test/fixtures/results/quickstart/nist_application.json @@ -419,7 +419,7 @@ }, { "Filename": "test/fixtures/templates/quickstart/nist_application.yaml", - "Id": "6ecda82c-9ccf-e772-b940-41eafbc02f6e", + "Id": "1613319d-ac84-a032-c510-b54d3061c0b1", "Level": "Warning", "Location": { "End": { @@ -438,7 +438,7 @@ "LineNumber": 379 } }, - "Message": "{'Ref': 'pAppAmi'} is not a 'AWS::EC2::Image.Id' when 'Ref' is resolved", + "Message": "{'Ref': 'pAppAmi'} is not a 'AWS::EC2::Image.Id' with pattern '' when 'Ref' is resolved", "ParentId": null, "Rule": { "Description": "Resolve the Ref and then validate the values against the schema", @@ -644,7 +644,7 @@ }, { "Filename": "test/fixtures/templates/quickstart/nist_application.yaml", - "Id": "300dd743-adad-ad4c-c09d-63fd5e9efcf2", + "Id": "a5d3cdc6-0e20-ebf4-e842-6341804c7ec3", "Level": "Warning", "Location": { "End": { @@ -663,7 +663,7 @@ "LineNumber": 511 } }, - "Message": "{'Ref': 'pWebServerAMI'} is not a 'AWS::EC2::Image.Id' when 'Ref' is resolved", + "Message": "{'Ref': 'pWebServerAMI'} is not a 'AWS::EC2::Image.Id' with pattern '' when 'Ref' is resolved", "ParentId": null, "Rule": { "Description": "Resolve the Ref and then validate the values against the schema", @@ -1672,7 +1672,7 @@ }, { "Filename": "test/fixtures/templates/quickstart/nist_application.yaml", - "Id": "ce028b65-d316-4519-8018-ac6ec0477964", + "Id": "ba50a58d-877c-2610-cc0f-4418059c3d40", "Level": "Warning", "Location": { "End": { @@ -1691,7 +1691,7 @@ "LineNumber": 801 } }, - "Message": "{'Ref': 'pWebServerAMI'} is not a 'AWS::EC2::Image.Id' when 'Ref' is resolved", + "Message": "{'Ref': 'pWebServerAMI'} is not a 'AWS::EC2::Image.Id' with pattern '' when 'Ref' is resolved", "ParentId": null, "Rule": { "Description": "Resolve the Ref and then validate the values against the schema", diff --git a/test/fixtures/results/quickstart/nist_vpc_management.json b/test/fixtures/results/quickstart/nist_vpc_management.json index f3166597b5..5a27a800ec 100644 --- a/test/fixtures/results/quickstart/nist_vpc_management.json +++ b/test/fixtures/results/quickstart/nist_vpc_management.json @@ -416,7 +416,7 @@ }, { "Filename": "test/fixtures/templates/quickstart/nist_vpc_management.yaml", - "Id": "f0f419da-862a-4317-0b95-8af2df6e8ad2", + "Id": "1c7a978c-0331-1e35-7ac6-6edc8d947e1c", "Level": "Warning", "Location": { "End": { @@ -435,7 +435,7 @@ "LineNumber": 513 } }, - "Message": "{'Ref': 'pBastionAmi'} is not a 'AWS::EC2::Image.Id' when 'Ref' is resolved", + "Message": "{'Ref': 'pBastionAmi'} is not a 'AWS::EC2::Image.Id' with pattern {'Ref': 'pBastionAmi'} when 'Ref' is resolved", "ParentId": null, "Rule": { "Description": "Resolve the Ref and then validate the values against the schema", diff --git a/test/fixtures/results/quickstart/non_strict/nist_application.json b/test/fixtures/results/quickstart/non_strict/nist_application.json index d1e295eacd..27448d3b25 100644 --- a/test/fixtures/results/quickstart/non_strict/nist_application.json +++ b/test/fixtures/results/quickstart/non_strict/nist_application.json @@ -419,7 +419,7 @@ }, { "Filename": "test/fixtures/templates/quickstart/nist_application.yaml", - "Id": "6ecda82c-9ccf-e772-b940-41eafbc02f6e", + "Id": "1613319d-ac84-a032-c510-b54d3061c0b1", "Level": "Warning", "Location": { "End": { @@ -438,7 +438,7 @@ "LineNumber": 379 } }, - "Message": "{'Ref': 'pAppAmi'} is not a 'AWS::EC2::Image.Id' when 'Ref' is resolved", + "Message": "{'Ref': 'pAppAmi'} is not a 'AWS::EC2::Image.Id' with pattern '' when 'Ref' is resolved", "ParentId": null, "Rule": { "Description": "Resolve the Ref and then validate the values against the schema", @@ -615,7 +615,7 @@ }, { "Filename": "test/fixtures/templates/quickstart/nist_application.yaml", - "Id": "300dd743-adad-ad4c-c09d-63fd5e9efcf2", + "Id": "a5d3cdc6-0e20-ebf4-e842-6341804c7ec3", "Level": "Warning", "Location": { "End": { @@ -634,7 +634,7 @@ "LineNumber": 511 } }, - "Message": "{'Ref': 'pWebServerAMI'} is not a 'AWS::EC2::Image.Id' when 'Ref' is resolved", + "Message": "{'Ref': 'pWebServerAMI'} is not a 'AWS::EC2::Image.Id' with pattern '' when 'Ref' is resolved", "ParentId": null, "Rule": { "Description": "Resolve the Ref and then validate the values against the schema", @@ -877,7 +877,7 @@ }, { "Filename": "test/fixtures/templates/quickstart/nist_application.yaml", - "Id": "ce028b65-d316-4519-8018-ac6ec0477964", + "Id": "ba50a58d-877c-2610-cc0f-4418059c3d40", "Level": "Warning", "Location": { "End": { @@ -896,7 +896,7 @@ "LineNumber": 801 } }, - "Message": "{'Ref': 'pWebServerAMI'} is not a 'AWS::EC2::Image.Id' when 'Ref' is resolved", + "Message": "{'Ref': 'pWebServerAMI'} is not a 'AWS::EC2::Image.Id' with pattern '' when 'Ref' is resolved", "ParentId": null, "Rule": { "Description": "Resolve the Ref and then validate the values against the schema", diff --git a/test/fixtures/templates/integration/formats.yaml b/test/fixtures/templates/integration/formats.yaml new file mode 100644 index 0000000000..2853b4ddf6 --- /dev/null +++ b/test/fixtures/templates/integration/formats.yaml @@ -0,0 +1,44 @@ +Parameters: + SecurityGroupsIds: + Type: List + SecurityGroupId: + Type: AWS::EC2::SecurityGroup::Id + +Resources: + Vpc: + Type: AWS::EC2::VPC + Properties: + CidrBlock: 10.0.0.0/16 + + Subnet: + Type: AWS::EC2::Subnet + Properties: + VpcId: !Ref Vpc + CidrBlock: 10.0.0.0/24 + + SecurityGroup: + Type: AWS::EC2::SecurityGroup + Properties: + VpcId: !Ref Vpc + GroupDescription: Some security group + + Instance1: + Type: AWS::EC2::Instance + Properties: + ImageId: ami-abcdef12 + InstanceType: t2.micro + NetworkInterfaces: + - DeviceIndex: 0 + SubnetId: !Ref Subnet + GroupSet: !Ref SecurityGroupsIds + - DeviceIndex: 1 + SubnetId: !Ref Subnet + GroupSet: + - !Ref SecurityGroupId + - !Ref SecurityGroup + - !GetAtt Vpc.DefaultSecurityGroup + - sg-dne + - DeviceIndex: 2 + SubnetId: !Ref Subnet + GroupSet: + - !GetAtt SecurityGroup.GroupName diff --git a/test/fixtures/templates/integration/getatt-types.yaml b/test/fixtures/templates/integration/getatt-types.yaml index 4a4d886723..6727d01add 100644 --- a/test/fixtures/templates/integration/getatt-types.yaml +++ b/test/fixtures/templates/integration/getatt-types.yaml @@ -22,6 +22,56 @@ Resources: Type: AWS::DocDB::DBCluster Properties: BackupRetentionPeriod: 1 + TestCluster: + Type: AWS::ECS::Cluster + TestFargateExecutionRole: + Type: AWS::IAM::Role + Properties: + AssumeRolePolicyDocument: + Statement: + - Action: + - sts:AssumeRole + Effect: Allow + Principal: + Service: ecs-tasks.amazonaws.com + ManagedPolicyArns: + - arn:aws:iam::aws:policy/service-role/AmazonECSTaskExecutionRolePolicy + + TestFargateTaskRole: + Type: AWS::IAM::Role + Properties: + AssumeRolePolicyDocument: + Statement: + - Action: + - sts:AssumeRole + Effect: Allow + Principal: + Service: ecs-tasks.amazonaws.com + TestLogGroup: + Type: AWS::Logs::LogGroup + DeletionPolicy: Delete + UpdateReplacePolicy: Delete + TestTaskDefinitionWithGetAtt: + Type: AWS::ECS::TaskDefinition + Properties: + ContainerDefinitions: + - Image: nginx:1.27.3-alpine3.20 + LogConfiguration: + LogDriver: awslogs + Options: + awslogs-group: !GetAtt 'TestLogGroup.Arn' + awslogs-region: !Ref 'AWS::Region' + awslogs-stream-prefix: test-service + Name: TestContainerDefinition + PortMappings: + - ContainerPort: 80 + Cpu: '256' + ExecutionRoleArn: !GetAtt 'TestFargateExecutionRole.Arn' + Memory: '512' + NetworkMode: awsvpc + RequiresCompatibilities: + - FARGATE + TaskRoleArn: !GetAtt 'TestFargateTaskRole.Arn' Outputs: Value: Value: 1 # OK diff --git a/test/fixtures/templates/integration/ref-types.yaml b/test/fixtures/templates/integration/ref-types.yaml new file mode 100644 index 0000000000..a02527c846 --- /dev/null +++ b/test/fixtures/templates/integration/ref-types.yaml @@ -0,0 +1,106 @@ +AWSTemplateFormatVersion: '2010-09-09' +Parameters: + AString: + Type: String + Default: default +Resources: + Cluster: + Type: AWS::ECS::Cluster + FargateExecutionRole: + Type: AWS::IAM::Role + Properties: + AssumeRolePolicyDocument: + Statement: + - Action: + - sts:AssumeRole + Effect: Allow + Principal: + Service: ecs-tasks.amazonaws.com + ManagedPolicyArns: + - arn:aws:iam::aws:policy/service-role/AmazonECSTaskExecutionRolePolicy + + FargateTaskRole: + Type: AWS::IAM::Role + Properties: + AssumeRolePolicyDocument: + Statement: + - Action: + - sts:AssumeRole + Effect: Allow + Principal: + Service: ecs-tasks.amazonaws.com + Vpc: + Type: AWS::EC2::VPC + Properties: + CidrBlock: 10.0.0.0/16 + Subnet1: + Type: AWS::EC2::Subnet + Properties: + CidrBlock: 10.0.1.0/24 + VpcId: !Ref Vpc + Subnet2: + Type: AWS::EC2::Subnet + Properties: + CidrBlock: 10.0.2.0/24 + VpcId: !Ref FargateTaskRole # Wrong type + SecurityGroup: + Type: AWS::EC2::SecurityGroup + Properties: + GroupDescription: SG + VpcId: !Ref Vpc + LoadBalancer: + Type: AWS::ElasticLoadBalancingV2::LoadBalancer + Properties: + Type: application + Scheme: internal + SecurityGroups: + - !Ref SecurityGroup + Subnets: + - !Ref Subnet1 + - !Ref Subnet2 + LogGroup: + Type: AWS::Logs::LogGroup + DeletionPolicy: Delete + UpdateReplacePolicy: Delete + TaskDefinitionWithRefToResource: + Type: AWS::ECS::TaskDefinition + Properties: + ContainerDefinitions: + - Image: nginx:1.27.3-alpine3.20 + LogConfiguration: + LogDriver: awslogs + Options: + awslogs-group: !Ref LogGroup + awslogs-region: !Ref 'AWS::Region' + awslogs-stream-prefix: test-service + Name: TestContainerDefinition + PortMappings: + - ContainerPort: 80 + Cpu: '256' + ExecutionRoleArn: !GetAtt 'FargateExecutionRole.Arn' + Memory: '512' + NetworkMode: awsvpc + RequiresCompatibilities: + - FARGATE + TaskRoleArn: !GetAtt 'FargateTaskRole.Arn' + TaskDefinitionWithRefToParameter: + Type: AWS::ECS::TaskDefinition + Properties: + ContainerDefinitions: + - Image: nginx:1.27.3-alpine3.20 + LogConfiguration: + LogDriver: awslogs + Options: + awslogs-group: !Ref AString + awslogs-region: !Ref 'AWS::Region' + awslogs-stream-prefix: test-service + Name: TestContainerDefinition + PortMappings: + - ContainerPort: 80 + Cpu: '256' + ExecutionRoleArn: !GetAtt 'FargateExecutionRole.Arn' + Memory: '512' + NetworkMode: awsvpc + RequiresCompatibilities: + - FARGATE + TaskRoleArn: !GetAtt 'FargateTaskRole.Arn' diff --git a/test/integration/test_integration_templates.py b/test/integration/test_integration_templates.py index 4b92d0d4a1..8d81cd0037 100644 --- a/test/integration/test_integration_templates.py +++ b/test/integration/test_integration_templates.py @@ -26,7 +26,7 @@ class TestQuickStartTemplates(BaseCliTestCase): { "filename": "test/fixtures/templates/integration/dynamic-references.yaml", "results_filename": ( - "test/fixtures/results/integration" "/dynamic-references.json" + "test/fixtures/results/integration/dynamic-references.json" ), "exit_code": 2, }, @@ -52,6 +52,16 @@ class TestQuickStartTemplates(BaseCliTestCase): "results_filename": ("test/fixtures/results/integration/getatt-types.json"), "exit_code": 10, }, + { + "filename": ("test/fixtures/templates/integration/ref-types.yaml"), + "results_filename": ("test/fixtures/results/integration/ref-types.json"), + "exit_code": 2, + }, + { + "filename": ("test/fixtures/templates/integration/formats.yaml"), + "results_filename": ("test/fixtures/results/integration/formats.json"), + "exit_code": 2, + }, { "filename": ( "test/fixtures/templates/integration/aws-ec2-networkinterface.yaml" diff --git a/test/unit/module/cfn_json/test_cfn_json.py b/test/unit/module/cfn_json/test_cfn_json.py index 2463c21e6c..f387d4bf3f 100644 --- a/test/unit/module/cfn_json/test_cfn_json.py +++ b/test/unit/module/cfn_json/test_cfn_json.py @@ -35,7 +35,7 @@ def setUp(self): }, "nat_instance": { "filename": "test/fixtures/templates/quickstart/nat-instance.json", - "failures": 4, + "failures": 7, }, "vpc_management": { "filename": "test/fixtures/templates/quickstart/vpc-management.json", diff --git a/test/unit/module/context/test_parameter.py b/test/unit/module/context/test_parameter.py index e081f418e9..0e5383c32e 100644 --- a/test/unit/module/context/test_parameter.py +++ b/test/unit/module/context/test_parameter.py @@ -12,7 +12,7 @@ @pytest.mark.parametrize( - "name,instance,expected_type,expected_ref", + "name,instance,expected_type,expected_ref_value", [ ("Valid string parameter", {"Type": "string"}, "string", []), ( @@ -89,14 +89,15 @@ ), ], ) -def test_parameter(name, instance, expected_type, expected_ref): +def test_parameter(name, instance, expected_type, expected_ref_value): context = Context(["us-east-1"]) parameter = Parameter(instance) assert expected_type == parameter.type - assert expected_ref == list( - parameter.ref(context) - ), f"{name!r} test got {list(parameter.ref(context))}" + assert expected_ref_value == list( + parameter.ref_value(context) + ), f"{name!r} test got {list(parameter.ref_value(context))}" + assert {} == parameter.ref() @pytest.mark.parametrize( diff --git a/test/unit/module/context/test_resource.py b/test/unit/module/context/test_resource.py index 582b054e43..55108447dd 100644 --- a/test/unit/module/context/test_resource.py +++ b/test/unit/module/context/test_resource.py @@ -5,23 +5,26 @@ import pytest -from cfnlint.context import Context from cfnlint.context.context import Resource, _init_resources @pytest.mark.parametrize( "name,instance,expected_ref", [ - ("Valid resource", {"Type": "AWS::S3::Bucket"}, []), + ( + "Valid resource", + {"Type": "AWS::EC2::VPC"}, + {"format": "AWS::EC2::VPC.Id", "type": "string"}, + ), ], ) def test_resource(name, instance, expected_ref): - context = Context(["us-east-1"]) - parameter = Resource(instance) + region = "us-east-1" + resource = Resource(instance) - assert expected_ref == list( - parameter.ref(context) - ), f"{name!r} test got {list(parameter.ref(context))}" + assert expected_ref == resource.ref( + region + ), f"{name!r} test got {resource.ref(region)}" @pytest.mark.parametrize( diff --git a/test/unit/module/schema/test_ref.py b/test/unit/module/schema/test_ref.py new file mode 100644 index 0000000000..3c47a164e3 --- /dev/null +++ b/test/unit/module/schema/test_ref.py @@ -0,0 +1,51 @@ +""" +Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +SPDX-License-Identifier: MIT-0 +""" + +import logging + +import pytest + +from cfnlint.schema._schema import Schema + +LOGGER = logging.getLogger("cfnlint.schema.manager") +LOGGER.disabled = True + + +@pytest.mark.parametrize( + "name,resource_schema,expected", + [ + ( + "Standard ref", + { + "additionalProperties": False, + "createOnlyProperties": [], + "primaryIdentifier": ["/properties/One"], + "properties": {"One": {"type": "string"}, "Two": {"type": "boolean"}}, + "readOnlyProperties": [], + "typeName": "Foo::Foo::Foo", + "writeOnlyProperties": [], + }, + {"type": "string"}, + ), + ( + "Standard with multiple identifiers", + { + "additionalProperties": False, + "createOnlyProperties": [], + "primaryIdentifier": ["/properties/One", "/properties/Two"], + "properties": {"One": {"type": "integer"}, "Two": {"type": "boolean"}}, + "readOnlyProperties": [], + "typeName": "Foo::Foo::Foo", + "writeOnlyProperties": [], + }, + {"type": "string"}, + ), + ], +) +def test_schema(name, resource_schema, expected): + + schema = Schema(resource_schema) + + assert schema.ref == expected, f"{name!r} test got {schema.ref!r}" diff --git a/test/unit/module/template/test_template_get_cfn_path.py b/test/unit/module/template/test_template_get_cfn_path.py new file mode 100644 index 0000000000..acea33e03f --- /dev/null +++ b/test/unit/module/template/test_template_get_cfn_path.py @@ -0,0 +1,127 @@ +""" +Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +SPDX-License-Identifier: MIT-0 +""" + +import pytest + +from cfnlint.template import Template + + +@pytest.fixture +def cfn() -> Template: + + return Template( + None, + { + "Parameters": { + "Environment": { + "Type": "String", + "AllowedValues": ["dev", "test", "stage", "prod"], + } + }, + "Conditions": { + "IsUsEast1": {"Fn::Equals": [{"Ref": "AWS::Region"}, "us-east-1"]}, + "IsProduction": {"Fn::Equals": [{"Ref": "Environment"}, "prod"]}, + }, + "Resources": { + "Bucket": {"Type": "AWS::S3::Bucket", "Condition": "IsUsEast1"}, + "Vpc": { + "Type": "AWS::EC2::VPC", + "Properties": {"CidrBlock": "10.0.0.0/16"}, + }, + "SecurityGroup1": { + "Type": "AWS::EC2::SecurityGroup", + "Condition": "IsProduction", + "Properties": { + "CidrBlock": "10.0.0.0/24", + "VpcId": { + "Fn::If": ["IsUsEast1", "vpc-123", {"Ref": "AWS::NoValue"}] + }, + }, + }, + "SecurityGroup2": { + "Type": "AWS::EC2::SecurityGroup", + "Condition": "IsProduction", + "Properties": { + "CidrBlock": "10.0.1.0/24", + "VpcId": { + "Fn::If": ["IsProduction", {"Ref": "Vpc"}, "vpc-abc"] + }, + }, + }, + }, + }, + ) + + +@pytest.mark.parametrize( + "name,path,starting_conditions, expected", + [ + ( + "Valid get path", + ["Resources", "Vpc", "Properties", "CidrBlock"], + {}, + [("10.0.0.0/16", {})], + ), + ( + "Invalid path returns nothing", + ["Resources", "Vpc", "Properties", "DNE"], + {}, + [], + ), + ( + "Short path that doesn't exist", + ["Resources", "DNE"], + {}, + [], + ), + ( + "Valid path with resource condition", + ["Resources", "SecurityGroup1", "Properties", "CidrBlock"], + {}, + [("10.0.0.0/24", {"IsProduction": True})], + ), + ( + "Valid path with resource condition", + ["Resources", "SecurityGroup1", "Properties", "CidrBlock"], + {"IsProduction": False}, + [], + ), + ( + "Valid path with resource condition with multiple conditions", + ["Resources", "SecurityGroup1", "Properties", "VpcId"], + {}, + [("vpc-123", {"IsProduction": True, "IsUsEast1": True})], + ), + ( + ( + "Valid path with resource condition with multiple " + "conditions that conflict with each other" + ), + ["Resources", "SecurityGroup2", "Properties", "VpcId"], + {}, + [({"Ref": "Vpc"}, {"IsProduction": True})], + ), + ], +) +def test_paths(name, path, starting_conditions, expected, cfn): + + context = cfn.context.evolve( + conditions=cfn.context.conditions.evolve(starting_conditions) + ) + + results = list(cfn.get_cfn_path(path, context)) + + assert len(results) == len( + expected + ), f"{name!r} test failed. Got results {results!r}" + + for i, value in enumerate(results): + assert ( + value[0] == expected[i][0] + ), f"{name!r} test failed for {i}. Got value {value[0]!r}" + assert value[1].conditions.status == expected[i][1], ( + f"{name!r} test failed for {i}. Got " + f"conditions {value[1].conditions.status[0]!r}" + ) diff --git a/test/unit/rules/formats/test_format.py b/test/unit/rules/formats/test_format.py index 541cc398c5..9bf34ab968 100644 --- a/test/unit/rules/formats/test_format.py +++ b/test/unit/rules/formats/test_format.py @@ -101,7 +101,7 @@ def format(self, validator, instance): }, [ ValidationError( - "'10.10.10.10' is not a 'test'", + "'10.10.10.10' is not a 'test' with pattern ''", rule=_Fail(), ) ], @@ -116,7 +116,7 @@ def format(self, validator, instance): }, [ ValidationError( - "'10.10.10.10' is not a 'test'", + "'10.10.10.10' is not a 'test' with pattern ''", rule=_Fail(), ) ], diff --git a/test/unit/rules/formats/test_log_group_name.py b/test/unit/rules/formats/test_log_group_name.py new file mode 100644 index 0000000000..2c27ab478d --- /dev/null +++ b/test/unit/rules/formats/test_log_group_name.py @@ -0,0 +1,42 @@ +""" +Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +SPDX-License-Identifier: MIT-0 +""" + +import pytest + +from cfnlint.rules.formats.LogGroupName import LogGroupName + + +@pytest.fixture(scope="module") +def rule(): + rule = LogGroupName() + yield rule + + +@pytest.mark.parametrize( + "name,instance,expected", + [ + ( + "Valid log group name", + "123457", + True, + ), + ( + "Valid with invalid type", + [], + True, + ), + ( + "Valid log group name with special characters", + "aws/one.two-three#four_five", + True, + ), + ("Invalid log group name because of special character", "foo&bar", False), + ("Invalid log group name because of empty", "", False), + ("Invalid log group name because too long", "a" * 513, False), + ], +) +def test_validate(name, instance, expected, rule, validator): + result = rule.format(validator, instance) + assert result == expected, f"Test {name!r} got {result!r}" diff --git a/test/unit/rules/formats/test_schema_comparer.py b/test/unit/rules/formats/test_schema_comparer.py new file mode 100644 index 0000000000..c41b1447f6 --- /dev/null +++ b/test/unit/rules/formats/test_schema_comparer.py @@ -0,0 +1,68 @@ +""" +Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +SPDX-License-Identifier: MIT-0 +""" + +import pytest + +from cfnlint.jsonschema import ValidationError +from cfnlint.rules.formats._schema_comparer import compare_schemas + + +@pytest.mark.parametrize( + "name,source,destination,expected", + [ + ( + "basic valid", + {"format": "foo"}, + {"format": "foo"}, + None, + ), + ( + "basic invalid", + {"format": "foo"}, + {"format": "bar"}, + ValidationError( + "'foo' format is incompatible with formats ['bar']", + ), + ), + ( + "basic invalid with no destination", + {"format": "foo"}, + {}, + ValidationError( + "'foo' format is incompatible", + ), + ), + ( + "basic valid with anyOf source", + {"anyOf": [{"format": "foo"}, {"format": "bar"}]}, + {"format": "foo"}, + None, + ), + ( + "basic valid with anyOf source with no valid formats", + {"anyOf": [{"format": "bar"}, {"format": "foobar"}]}, + {"format": "foo"}, + None, + ), + ( + "basic valid with anyOf destination", + {"format": "foo"}, + {"anyOf": [{"format": "foo"}, {"format": "bar"}]}, + None, + ), + ( + "basic invalid with anyOf destination with many invalid", + {"format": "foo"}, + {"anyOf": [{"format": "bar"}, {"format": "foobar"}]}, + ValidationError( + "'foo' format is incompatible with formats ['bar', 'foobar']", + ), + ), + ], +) +def test_schema_comparer(name, source, destination, expected): + result = compare_schemas(source, destination) + + assert result == expected, f"{name!r} got errors {result!r}" diff --git a/test/unit/rules/functions/test_getatt_format.py b/test/unit/rules/functions/test_getatt_format.py index e3b3d596b6..51474f022e 100644 --- a/test/unit/rules/functions/test_getatt_format.py +++ b/test/unit/rules/functions/test_getatt_format.py @@ -78,8 +78,23 @@ def template(): [ ValidationError( ( - "{'Fn::GetAtt': ['MyBucket', 'Arn']} that " - "does not match 'AWS::EC2::VPC.Id'" + "{'Fn::GetAtt': ['MyBucket', 'Arn']} " + "does not match destination format of 'AWS::EC2::VPC.Id'" + ), + rule=GetAttFormat(), + ) + ], + ), + ( + "Invalid GetAtt with a getatt and no format", + ["MyBucket", "WebsiteURL"], + {"format": "AWS::EC2::VPC.Id"}, + [ + ValidationError( + ( + "{'Fn::GetAtt': ['MyBucket', 'WebsiteURL']} " + "with format 'uri' does not match " + "destination format of 'AWS::EC2::VPC.Id'" ), rule=GetAttFormat(), ) diff --git a/test/unit/rules/functions/test_ref_format.py b/test/unit/rules/functions/test_ref_format.py new file mode 100644 index 0000000000..9e13087c03 --- /dev/null +++ b/test/unit/rules/functions/test_ref_format.py @@ -0,0 +1,76 @@ +""" +Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +SPDX-License-Identifier: MIT-0 +""" + +import pytest + +from cfnlint.jsonschema import ValidationError +from cfnlint.rules.functions.RefFormat import RefFormat + + +@pytest.fixture(scope="module") +def rule(): + rule = RefFormat() + yield rule + + +@pytest.fixture +def template(): + return { + "Resources": { + "MyBucket": {"Type": "AWS::S3::Bucket"}, + "MyVpc": {"Type": "AWS::EC2::VPC"}, + }, + } + + +@pytest.mark.parametrize( + "name,instance,schema,expected", + [ + ( + "Valid Ref with a good format", + "MyVpc", + {"format": "AWS::EC2::VPC.Id"}, + [], + ), + ( + "Invalid Ref with a bad format", + "MyVpc", + {"format": "AWS::EC2::Image.Id"}, + [ + ValidationError( + ( + "{'Ref': 'MyVpc'} with formats " + "['AWS::EC2::VPC.Id'] does not match " + "destination format of 'AWS::EC2::Image.Id'" + ), + rule=RefFormat(), + ) + ], + ), + ( + "Invalid Ref with a resource with no format", + "MyBucket", + {"format": "AWS::EC2::Image.Id"}, + [ + ValidationError( + ( + "{'Ref': 'MyBucket'} does not match " + "destination format of 'AWS::EC2::Image.Id'" + ), + rule=RefFormat(), + ) + ], + ), + ( + "Invalid Ref to non existent resource", + "DNE", + {"format": "AWS::EC2::Image.Id"}, + [], + ), + ], +) +def test_validate(name, instance, schema, expected, rule, validator): + errs = list(rule.validate(validator, schema, instance, schema)) + assert errs == expected, f"Test {name!r} got {errs!r}" diff --git a/test/unit/rules/parameters/test_dynamic_reference_secret.py b/test/unit/rules/parameters/test_dynamic_reference_secret.py index fe6c663ed4..fc559a55ce 100644 --- a/test/unit/rules/parameters/test_dynamic_reference_secret.py +++ b/test/unit/rules/parameters/test_dynamic_reference_secret.py @@ -45,19 +45,19 @@ def context(cfn): [ ( "REFing a parameter without a string", - {"Ref": []}, + [], deque([]), [], ), ( "REFing a resource=", - {"Ref": "MyResource"}, + "MyResource", deque([]), [], ), ( "REFing a parameter", - {"Ref": "MyParameter"}, + "MyParameter", deque([]), [ ValidationError( @@ -68,7 +68,7 @@ def context(cfn): ), ( "REFing a parameter in a sub", - {"Ref": "MyParameter"}, + "MyParameter", deque(["Fn::Sub"]), [], ), diff --git a/test/unit/rules/parameters/test_no_echo.py b/test/unit/rules/parameters/test_no_echo.py index 471dedca45..178a0e1d1d 100644 --- a/test/unit/rules/parameters/test_no_echo.py +++ b/test/unit/rules/parameters/test_no_echo.py @@ -49,25 +49,25 @@ def context(cfn): [ ( "An Invalid Ref", - {"Ref": []}, + [], deque(["Metadata"]), [], ), ( "A ref to something that isn't a parameter", - {"Ref": "AWS::Region"}, + "AWS::Region", deque(["Metadata"]), [], ), ( "Using NoEcho in Resources Properties", - {"Ref": "Echo"}, + "Echo", deque(["Resources", "MyResource", "Properties", "Name"]), [], ), ( "Using NoEcho in Resource Metadata", - {"Ref": "Echo"}, + "Echo", deque(["Resources", "MyResource", "Metadata"]), [ ValidationError( @@ -79,7 +79,7 @@ def context(cfn): ), ( "Using NoEcho in Metadata", - {"Ref": "Echo"}, + "Echo", deque(["Metadata"]), [ ValidationError( @@ -91,7 +91,7 @@ def context(cfn): ), ( "Using NoEcho in Metadata", - {"Ref": "EchoTrue"}, + "EchoTrue", deque(["Metadata"]), [ ValidationError( @@ -103,25 +103,25 @@ def context(cfn): ), ( "Using Non NoEcho in Metadata", - {"Ref": "NoEcho"}, + "NoEcho", deque(["Metadata"]), [], ), ( "Using a parameter in Metadata", - {"Ref": "MyParameter"}, + "MyParameter", deque(["Metadata"]), [], ), ( "Short list for path", - {"Ref": "MyParameter"}, + "MyParameter", deque([]), [], ), ( "Using NoEcho in Outputs", - {"Ref": "Echo"}, + "Echo", deque(["Outputs", "Name", "Value"]), [ ValidationError( diff --git a/test/unit/rules/resources/ec2/test_private_ip_with_network_interafce.py b/test/unit/rules/resources/ec2/test_private_ip_with_network_interafce.py index 23f087af94..ea3615250c 100644 --- a/test/unit/rules/resources/ec2/test_private_ip_with_network_interafce.py +++ b/test/unit/rules/resources/ec2/test_private_ip_with_network_interafce.py @@ -190,11 +190,6 @@ def rule(): def test_validate(name, instance, expected, rule, validator): errs = list(rule.validate(validator, "", instance, {})) - for err in errs: - print(err.validator) - print(err.path) - print(err.schema_path) - assert ( errs == expected ), f"Expected test {name!r} to have {expected!r} but got {errs!r}" diff --git a/test/unit/rules/resources/properties/test_image_id.py b/test/unit/rules/resources/properties/test_image_id.py index c2fbb2385b..c06eeaf5b6 100644 --- a/test/unit/rules/resources/properties/test_image_id.py +++ b/test/unit/rules/resources/properties/test_image_id.py @@ -37,17 +37,17 @@ def template(): [ ( "Valid Ref to a paraemter", - {"Ref": "MyImageId"}, + "MyImageId", [], ), ( "Valid Ref to a Pseudo-Parameter", - {"Ref": "AWS::Region"}, + "AWS::Region", [], ), ( "Invalid Ref to a parameter of the wrong type", - {"Ref": "MyString"}, + "MyString", [ ValidationError( (