@intentius/chant-lexicon-aws 0.124.30 → 0.124.32
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/actions/dynamodb.js +41 -0
- package/dist/actions/ecr.js +9 -0
- package/dist/actions/ecs.js +5 -0
- package/dist/actions/iam.js +3 -0
- package/dist/actions/index.js +9 -0
- package/dist/actions/lambda.js +11 -0
- package/dist/actions/logs.js +4 -0
- package/dist/actions/s3.js +40 -0
- package/dist/actions/sns.js +5 -0
- package/dist/actions/sqs.js +15 -0
- package/dist/agentcore/trace-fetch.d.ts.map +1 -1
- package/dist/agentcore/trace-fetch.js +472 -0
- package/dist/agentcore/trace-render.js +359 -0
- package/dist/ambient.js +148 -0
- package/dist/api/credential-chain.d.ts +30 -3
- package/dist/api/credential-chain.d.ts.map +1 -1
- package/dist/api/credential-chain.js +509 -0
- package/dist/api/read-client.d.ts +16 -43
- package/dist/api/read-client.d.ts.map +1 -1
- package/dist/api/read-client.js +458 -0
- package/dist/api/sigv4.d.ts +4 -4
- package/dist/api/sigv4.js +185 -0
- package/dist/behaviour-kinds.js +114 -0
- package/dist/caller-identity.d.ts +3 -5
- package/dist/caller-identity.d.ts.map +1 -1
- package/dist/caller-identity.js +146 -0
- package/dist/codegen/docs-cli.js +2 -0
- package/dist/codegen/docs.js +120 -0
- package/dist/codegen/enum-overlay.js +162 -0
- package/dist/codegen/extensions.js +139 -0
- package/dist/codegen/fallback.js +32 -0
- package/dist/codegen/generate-cli.js +15 -0
- package/dist/codegen/generate-lexicon.js +70 -0
- package/dist/codegen/generate-typescript.js +226 -0
- package/dist/codegen/generate.d.ts.map +1 -1
- package/dist/codegen/generate.js +234 -0
- package/dist/codegen/naming.js +135 -0
- package/dist/codegen/package.js +67 -0
- package/dist/codegen/patches.d.ts +26 -1
- package/dist/codegen/patches.d.ts.map +1 -1
- package/dist/codegen/patches.js +90 -0
- package/dist/codegen/property-overlay.js +85 -0
- package/dist/codegen/property-overlay.json +1 -16
- package/dist/codegen/sam.js +402 -0
- package/dist/codegen/typecheck.js +4 -0
- package/dist/codegen/versions.js +31 -0
- package/dist/components/__tests__/mock-cloud-executor.js +326 -0
- package/dist/components/apply.d.ts +44 -1
- package/dist/components/apply.d.ts.map +1 -1
- package/dist/components/apply.js +752 -0
- package/dist/components/builders.js +37 -0
- package/dist/components/capability-plugin.js +66 -0
- package/dist/components/cloud-executor.d.ts +35 -0
- package/dist/components/cloud-executor.d.ts.map +1 -1
- package/dist/components/cloud-executor.js +576 -0
- package/dist/components/config-bom.js +207 -0
- package/dist/components/host-delivery.js +117 -0
- package/dist/components/index.js +18 -0
- package/dist/components/job-submission.js +77 -0
- package/dist/components/publish.js +234 -0
- package/dist/components/safety.js +62 -0
- package/dist/components/wait-aws.js +68 -0
- package/dist/composites/agentcore-agent.js +187 -0
- package/dist/composites/agentcore-trust-policy.js +13 -0
- package/dist/composites/alb-shared.js +84 -0
- package/dist/composites/bucket-deployment.js +93 -0
- package/dist/composites/catalog.js +2714 -0
- package/dist/composites/dynamodb-table.js +66 -0
- package/dist/composites/ec2-instance-bundle.js +75 -0
- package/dist/composites/ec2-instance-role.js +26 -0
- package/dist/composites/ecr-repository.js +64 -0
- package/dist/composites/ecs-trust-policy.js +10 -0
- package/dist/composites/efs-with-access-point.js +44 -0
- package/dist/composites/eks-cluster.js +118 -0
- package/dist/composites/fargate-alb.js +216 -0
- package/dist/composites/fargate-service.js +222 -0
- package/dist/composites/index.js +28 -0
- package/dist/composites/lambda-api.js +15 -0
- package/dist/composites/lambda-dynamodb.js +77 -0
- package/dist/composites/lambda-eventbridge.js +27 -0
- package/dist/composites/lambda-function.js +54 -0
- package/dist/composites/lambda-s3.js +93 -0
- package/dist/composites/lambda-sns.js +23 -0
- package/dist/composites/lambda-sqs.js +34 -0
- package/dist/composites/landing-zone.js +82 -0
- package/dist/composites/microvm-app.js +293 -0
- package/dist/composites/minimal-vpc.js +40 -0
- package/dist/composites/monitoring-stack.js +105 -0
- package/dist/composites/nlb-service.js +61 -0
- package/dist/composites/rds-instance.js +98 -0
- package/dist/composites/scheduled-lambda.js +28 -0
- package/dist/composites/solr-fargate-service.js +33 -0
- package/dist/composites/step-functions-workflow.js +78 -0
- package/dist/composites/vpc-default.js +132 -0
- package/dist/condition.js +43 -0
- package/dist/coverage.js +4 -0
- package/dist/deep-observe.d.ts.map +1 -1
- package/dist/deep-observe.js +709 -0
- package/dist/deep-topology.js +226 -0
- package/dist/default-tags.js +50 -0
- package/dist/defaults.js +85 -0
- package/dist/dependencies.js +269 -0
- package/dist/detect.js +21 -0
- package/dist/disruption.d.ts.map +1 -1
- package/dist/disruption.js +129 -0
- package/dist/effect-receipt-row.js +107 -0
- package/dist/generated/index.d.ts +1297 -82
- package/dist/generated/index.d.ts.map +1 -1
- package/dist/generated/index.js +12382 -0
- package/dist/generated/runtime.js +4 -0
- package/dist/governance.js +131 -0
- package/dist/identity-observe.d.ts.map +1 -1
- package/dist/identity-observe.js +127 -0
- package/dist/import/generator.js +757 -0
- package/dist/import/live-export.js +34 -0
- package/dist/import/parser.js +394 -0
- package/dist/index.js +69 -0
- package/dist/integrity.json +6 -6
- package/dist/intrinsics.js +393 -0
- package/dist/lint/audit-catalog.js +87 -0
- package/dist/lint/audit-lineage.js +150 -0
- package/dist/lint/post-synth/cf-refs.js +247 -0
- package/dist/lint/post-synth/cor020.js +60 -0
- package/dist/lint/post-synth/ext001.d.ts.map +1 -1
- package/dist/lint/post-synth/ext001.js +197 -0
- package/dist/lint/post-synth/index.js +124 -0
- package/dist/lint/post-synth/waw010.js +41 -0
- package/dist/lint/post-synth/waw011.js +41 -0
- package/dist/lint/post-synth/waw013.js +38 -0
- package/dist/lint/post-synth/waw014.js +42 -0
- package/dist/lint/post-synth/waw015.js +88 -0
- package/dist/lint/post-synth/waw016.d.ts.map +1 -1
- package/dist/lint/post-synth/waw016.js +116 -0
- package/dist/lint/post-synth/waw017.js +43 -0
- package/dist/lint/post-synth/waw018.js +61 -0
- package/dist/lint/post-synth/waw019.js +64 -0
- package/dist/lint/post-synth/waw020.js +56 -0
- package/dist/lint/post-synth/waw021.js +44 -0
- package/dist/lint/post-synth/waw022.js +36 -0
- package/dist/lint/post-synth/waw023.js +40 -0
- package/dist/lint/post-synth/waw024.js +46 -0
- package/dist/lint/post-synth/waw025.js +36 -0
- package/dist/lint/post-synth/waw026.js +38 -0
- package/dist/lint/post-synth/waw027.js +41 -0
- package/dist/lint/post-synth/waw028.js +39 -0
- package/dist/lint/post-synth/waw029.js +54 -0
- package/dist/lint/post-synth/waw030.js +282 -0
- package/dist/lint/post-synth/waw031.js +58 -0
- package/dist/lint/post-synth/waw032.js +45 -0
- package/dist/lint/post-synth/waw033.js +75 -0
- package/dist/lint/post-synth/waw034.js +52 -0
- package/dist/lint/post-synth/waw035.js +56 -0
- package/dist/lint/post-synth/waw036.js +79 -0
- package/dist/lint/post-synth/waw037.js +67 -0
- package/dist/lint/post-synth/waw038.js +42 -0
- package/dist/lint/post-synth/waw039.js +42 -0
- package/dist/lint/post-synth/waw040.js +45 -0
- package/dist/lint/post-synth/waw041.js +40 -0
- package/dist/lint/post-synth/waw042.js +99 -0
- package/dist/lint/post-synth/waw043.js +51 -0
- package/dist/lint/post-synth/waw044.js +64 -0
- package/dist/lint/post-synth/waw045.js +49 -0
- package/dist/lint/post-synth/waw046.js +52 -0
- package/dist/lint/post-synth/waw047.js +43 -0
- package/dist/lint/post-synth/waw048.js +40 -0
- package/dist/lint/post-synth/waw049.js +78 -0
- package/dist/lint/post-synth/waw050.js +44 -0
- package/dist/lint/post-synth/waw051.js +41 -0
- package/dist/lint/post-synth/waw052.js +43 -0
- package/dist/lint/post-synth/waw053.js +43 -0
- package/dist/lint/post-synth/waw054.js +41 -0
- package/dist/lint/post-synth/waw055.js +41 -0
- package/dist/lint/post-synth/waw056.js +65 -0
- package/dist/lint/post-synth/waw057.js +43 -0
- package/dist/lint/post-synth/waw058.js +61 -0
- package/dist/lint/post-synth/waw059.js +338 -0
- package/dist/lint/post-synth/waw060.js +83 -0
- package/dist/lint/post-synth/waw061.js +60 -0
- package/dist/lint/post-synth/waw062.js +0 -0
- package/dist/lint/post-synth/waw063.js +0 -0
- package/dist/lint/post-synth/waw064.js +45 -0
- package/dist/lint/post-synth/waw065.js +104 -0
- package/dist/lint/post-synth/waw066.js +145 -0
- package/dist/lint/post-synth/waw067.js +115 -0
- package/dist/lint/post-synth/waw068.js +69 -0
- package/dist/lint/post-synth/waw069.js +0 -0
- package/dist/lint/rules/hardcoded-region.js +38 -0
- package/dist/lint/rules/iam-wildcard.js +60 -0
- package/dist/lint/rules/index.js +6 -0
- package/dist/lint/rules/s3-encryption.js +60 -0
- package/dist/live-attrs.js +42 -0
- package/dist/lsp/completions.d.ts.map +1 -1
- package/dist/lsp/completions.js +18 -0
- package/dist/lsp/hover.d.ts.map +1 -1
- package/dist/lsp/hover.js +66 -0
- package/dist/manifest.json +1 -1
- package/dist/mapping.js +33 -0
- package/dist/meta.json +17359 -784
- package/dist/nested-stack.js +95 -0
- package/dist/okf/index.md +203 -0
- package/dist/okf/rules/EXT001.md +1 -0
- package/dist/okf/rules/WAW016.md +2 -0
- package/dist/okf/rules/WAW019.md +1 -0
- package/dist/okf/rules/WAW028.md +1 -0
- package/dist/okf/rules/WAW030.md +2 -0
- package/dist/okf/rules/WAW039.md +1 -0
- package/dist/okf/rules/WAW049.md +1 -0
- package/dist/okf/rules/WAW056.md +1 -0
- package/dist/okf/rules/WAW058.md +1 -0
- package/dist/okf/rules/WAW062.md +1 -0
- package/dist/okf/rules/WAW064.md +1 -0
- package/dist/okf/rules/WAW065.md +1 -0
- package/dist/okf/rules/WAW066.md +1 -0
- package/dist/okf/rules/WAW067.md +1 -0
- package/dist/okf/rules/WAW068.md +1 -0
- package/dist/okf/rules/WAW069.md +4 -0
- package/dist/okf/types/AIWorkloadConfig.md +23 -0
- package/dist/okf/types/ARCRegionSwitchPlan.md +1 -0
- package/dist/okf/types/AccountAccessApplication.md +28 -0
- package/dist/okf/types/AccountAccessEntitlement.md +22 -0
- package/dist/okf/types/ActionTarget.md +20 -0
- package/dist/okf/types/AdConfiguration.md +21 -0
- package/dist/okf/types/Adapter.md +26 -0
- package/dist/okf/types/AgentContext.md +35 -0
- package/dist/okf/types/AgentGoal.md +31 -0
- package/dist/okf/types/AgentProfile.md +34 -0
- package/dist/okf/types/Alarm.md +3 -1
- package/dist/okf/types/AlarmModel.md +14 -9
- package/dist/okf/types/AmplifyWebhook.md +25 -0
- package/dist/okf/types/ApiCache.md +8 -8
- package/dist/okf/types/ApiGatewayManagedOverrides.md +5 -5
- package/dist/okf/types/AppAuthorization.md +35 -0
- package/dist/okf/types/AppBlockBuilder.md +1 -0
- package/dist/okf/types/AppInstance.md +2 -2
- package/dist/okf/types/AppInstanceBot.md +2 -2
- package/dist/okf/types/AppStreamFleet.md +3 -2
- package/dist/okf/types/AppSyncApiKey.md +6 -6
- package/dist/okf/types/AppSyncType.md +22 -0
- package/dist/okf/types/ApplicationStatusCheck.md +36 -0
- package/dist/okf/types/ApplicationVersion.md +4 -1
- package/dist/okf/types/ApplicationsList.md +26 -0
- package/dist/okf/types/ApprovalPolicy.md +28 -0
- package/dist/okf/types/ArchiveRule.md +24 -0
- package/dist/okf/types/Asset.md +30 -0
- package/dist/okf/types/Backup.md +31 -0
- package/dist/okf/types/BedrockAgentCoreDataset.md +1 -1
- package/dist/okf/types/BedrockAgentCoreGateway.md +3 -0
- package/dist/okf/types/BedrockSession.md +28 -0
- package/dist/okf/types/BillEstimate.md +35 -0
- package/dist/okf/types/Brand.md +32 -0
- package/dist/okf/types/CallAnalyticsCategory.md +25 -0
- package/dist/okf/types/Campaign.md +28 -0
- package/dist/okf/types/CapacityProvider.md +30 -0
- package/dist/okf/types/Case.md +24 -0
- package/dist/okf/types/CertificateAssociation.md +13 -0
- package/dist/okf/types/ChangeSet.md +36 -0
- package/dist/okf/types/ChannelFlow.md +29 -0
- package/dist/okf/types/ChimeChannel.md +39 -0
- package/dist/okf/types/Classifier.md +6 -6
- package/dist/okf/types/ClientVpnAuthorizationRule.md +6 -6
- package/dist/okf/types/ClientVpnEndpoint.md +2 -0
- package/dist/okf/types/ClientVpnRoute.md +5 -5
- package/dist/okf/types/CloudConnector.md +29 -0
- package/dist/okf/types/Cluster.md +39 -0
- package/dist/okf/types/ClusterSchedulerConfig.md +30 -0
- package/dist/okf/types/CodeCommitRepository.md +12 -12
- package/dist/okf/types/CodeConnectionsHost.md +26 -0
- package/dist/okf/types/CodeRepository.md +5 -5
- package/dist/okf/types/CompositeAlarm.md +1 -0
- package/dist/okf/types/ComputeEnvironment.md +2 -0
- package/dist/okf/types/ComputeNodeGroup.md +1 -1
- package/dist/okf/types/ComputeQuota.md +34 -0
- package/dist/okf/types/ConfigRule.md +1 -1
- package/dist/okf/types/ConfigurationRecorder.md +7 -6
- package/dist/okf/types/ConnectAttachment.md +2 -0
- package/dist/okf/types/ConnectQueue.md +5 -1
- package/dist/okf/types/ConnectVocabulary.md +28 -0
- package/dist/okf/types/ConnectionType.md +24 -0
- package/dist/okf/types/ConsentPortal.md +33 -0
- package/dist/okf/types/ContactMethod.md +29 -0
- package/dist/okf/types/ContainerAssociation.md +26 -0
- package/dist/okf/types/ContainerFleet.md +1 -1
- package/dist/okf/types/ContainerGroupDefinition.md +1 -1
- package/dist/okf/types/Content.md +40 -0
- package/dist/okf/types/ContentAssociation.md +28 -0
- package/dist/okf/types/CustomDetectionRuleAssociation.md +28 -0
- package/dist/okf/types/CustomEntityType.md +4 -9
- package/dist/okf/types/Customization.md +22 -0
- package/dist/okf/types/CwIntegration.md +31 -0
- package/dist/okf/types/DAXParameterGroup.md +3 -8
- package/dist/okf/types/DAXSubnetGroup.md +0 -5
- package/dist/okf/types/DBClusterEndpoint.md +31 -0
- package/dist/okf/types/DBProxyTargetGroup.md +1 -0
- package/dist/okf/types/DBSnapshot.md +62 -0
- package/dist/okf/types/DLMLifecyclePolicy.md +12 -12
- package/dist/okf/types/DLPSetting.md +31 -0
- package/dist/okf/types/DMSInstanceProfile.md +1 -1
- package/dist/okf/types/DRSLaunchConfigurationTemplate.md +28 -0
- package/dist/okf/types/Daemon.md +1 -0
- package/dist/okf/types/DataExchangeDataSet.md +29 -0
- package/dist/okf/types/DataIntegrationFlow.md +27 -0
- package/dist/okf/types/DataMigration.md +1 -1
- package/dist/okf/types/DataProvider.md +2 -1
- package/dist/okf/types/DataQualityRuleset.md +6 -11
- package/dist/okf/types/DataSource.md +23 -0
- package/dist/okf/types/Dataset.md +20 -0
- package/dist/okf/types/DatasetIntegration.md +23 -0
- package/dist/okf/types/DbCluster.md +1 -1
- package/dist/okf/types/DbInstance.md +8 -2
- package/dist/okf/types/DeadlineBudget.md +29 -0
- package/dist/okf/types/DelegationSet.md +23 -0
- package/dist/okf/types/DeliveryChannel.md +6 -11
- package/dist/okf/types/DevOpsAgentAgentSpace.md +4 -0
- package/dist/okf/types/DevOpsAgentService.md +1 -0
- package/dist/okf/types/DevOpsAgentTrigger.md +28 -0
- package/dist/okf/types/DirectConnectGatewayAttachment.md +2 -0
- package/dist/okf/types/Directory.md +60 -0
- package/dist/okf/types/DocDBDBClusterParameterGroup.md +5 -10
- package/dist/okf/types/DocDBDBSubnetGroup.md +4 -9
- package/dist/okf/types/DocDBElasticClusterSnapshot.md +36 -0
- package/dist/okf/types/DocumentClassifierEndpoint.md +27 -0
- package/dist/okf/types/Domain.md +27 -0
- package/dist/okf/types/EKSCertificateAuthority.md +42 -0
- package/dist/okf/types/EKSCluster.md +8 -0
- package/dist/okf/types/EcSnapshot.md +66 -0
- package/dist/okf/types/EmailIdentityCertificate.md +15 -0
- package/dist/okf/types/EndpointConfig.md +14 -13
- package/dist/okf/types/EntityRecognizer.md +27 -0
- package/dist/okf/types/EntityRecognizerEndpoint.md +31 -0
- package/dist/okf/types/EnvironmentEC2.md +13 -13
- package/dist/okf/types/EvaluationForm.md +1 -0
- package/dist/okf/types/Evaluator.md +6 -2
- package/dist/okf/types/EventAction.md +26 -0
- package/dist/okf/types/EventRule.md +2 -0
- package/dist/okf/types/EventSource.md +30 -0
- package/dist/okf/types/EventTracker.md +22 -0
- package/dist/okf/types/EventsV2EventBus.md +28 -0
- package/dist/okf/types/EventsV2ResourcePolicy.md +19 -0
- package/dist/okf/types/EventsV2Subscriber.md +39 -0
- package/dist/okf/types/ExperimentDefinition.md +39 -0
- package/dist/okf/types/ExperimentRun.md +33 -0
- package/dist/okf/types/ExperimentTrialComponent.md +13 -11
- package/dist/okf/types/FHIRDatastore.md +3 -0
- package/dist/okf/types/FSxSnapshot.md +5 -5
- package/dist/okf/types/FSxVolume.md +9 -9
- package/dist/okf/types/FeaturedResultsSet.md +26 -0
- package/dist/okf/types/Feed.md +1 -0
- package/dist/okf/types/FieldLevelEncryptionConfig.md +25 -0
- package/dist/okf/types/FieldLevelEncryptionProfile.md +22 -0
- package/dist/okf/types/FileCache.md +45 -0
- package/dist/okf/types/Filter.md +27 -0
- package/dist/okf/types/Firewall.md +6 -0
- package/dist/okf/types/FlowMediaStream.md +28 -0
- package/dist/okf/types/FlowOutput.md +1 -0
- package/dist/okf/types/FpgaImage.md +38 -0
- package/dist/okf/types/Function.md +2 -2
- package/dist/okf/types/Gateway.md +41 -0
- package/dist/okf/types/GatewayClusterAssociations.md +23 -0
- package/dist/okf/types/GatewayRateLimit.md +26 -0
- package/dist/okf/types/GatewayRule.md +32 -0
- package/dist/okf/types/GlobalReplicationGroup.md +3 -0
- package/dist/okf/types/GlobalResolver.md +1 -1
- package/dist/okf/types/GlobalTable.md +1 -0
- package/dist/okf/types/GlueConnection.md +5 -4
- package/dist/okf/types/GlueSecurityConfiguration.md +1 -6
- package/dist/okf/types/GlueSession.md +38 -0
- package/dist/okf/types/GlueTable.md +5 -10
- package/dist/okf/types/GlueWorkflow.md +5 -10
- package/dist/okf/types/Group.md +27 -0
- package/dist/okf/types/Harness.md +1 -0
- package/dist/okf/types/HostKey.md +33 -0
- package/dist/okf/types/HostedZone.md +1 -0
- package/dist/okf/types/HttpApi.md +2 -0
- package/dist/okf/types/HttpNamespace.md +5 -5
- package/dist/okf/types/HubV2.md +1 -0
- package/dist/okf/types/HumanTaskUi.md +22 -0
- package/dist/okf/types/IPv4Pool.md +28 -0
- package/dist/okf/types/ImageBuilder.md +1 -0
- package/dist/okf/types/ImageBuilderImage.md +1 -1
- package/dist/okf/types/ImagePipeline.md +1 -1
- package/dist/okf/types/InferenceComponent.md +5 -1
- package/dist/okf/types/InfluxDBBackup.md +65 -0
- package/dist/okf/types/InfluxDBCluster.md +3 -0
- package/dist/okf/types/InfrastructureConfiguration.md +2 -0
- package/dist/okf/types/IngestionDestination.md +28 -0
- package/dist/okf/types/InputSecurityGroup.md +6 -4
- package/dist/okf/types/InspectorV2Connector.md +38 -0
- package/dist/okf/types/InstanceEventWindow.md +25 -0
- package/dist/okf/types/InstanceFleetConfig.md +10 -10
- package/dist/okf/types/InstanceGroupConfig.md +3 -3
- package/dist/okf/types/InstrumentationConfig.md +31 -0
- package/dist/okf/types/IntegrationAssociation.md +3 -0
- package/dist/okf/types/IoTSiteWiseApplication.md +34 -0
- package/dist/okf/types/IoTSiteWiseDataset.md +5 -2
- package/dist/okf/types/IoTSiteWiseTask.md +24 -0
- package/dist/okf/types/IpamExternalResourceVerificationToken.md +35 -0
- package/dist/okf/types/IpamInternetRegistryAssociation.md +32 -0
- package/dist/okf/types/Job.md +35 -0
- package/dist/okf/types/JobTemplate.md +26 -0
- package/dist/okf/types/KinesisChannel.md +31 -0
- package/dist/okf/types/KinesisStream.md +1 -0
- package/dist/okf/types/LambdaResourcePolicy.md +14 -0
- package/dist/okf/types/Lexicon.md +34 -0
- package/dist/okf/types/LicenseAssetGroup.md +23 -0
- package/dist/okf/types/LicenseConfiguration.md +33 -0
- package/dist/okf/types/LicenseServerEndpoint.md +32 -0
- package/dist/okf/types/LightsailKeyPair.md +29 -0
- package/dist/okf/types/LimitsProfile.md +27 -0
- package/dist/okf/types/LocationAzureBlob.md +2 -1
- package/dist/okf/types/LocationObjectStorage.md +1 -0
- package/dist/okf/types/LogAlarm.md +2 -0
- package/dist/okf/types/MGNConnector.md +23 -0
- package/dist/okf/types/MGNLaunchConfigurationTemplate.md +37 -0
- package/dist/okf/types/MLTransform.md +15 -15
- package/dist/okf/types/MWAAServerlessWorkflow.md +3 -0
- package/dist/okf/types/ManagedNotificationAccountContactAssociation.md +1 -0
- package/dist/okf/types/ManagedNotificationAdditionalChannelAssociation.md +1 -0
- package/dist/okf/types/MediaConvertJobTemplate.md +11 -13
- package/dist/okf/types/MediaConvertQueue.md +8 -10
- package/dist/okf/types/MediaInsightsPipelineConfiguration.md +28 -0
- package/dist/okf/types/MediaLiveInput.md +41 -18
- package/dist/okf/types/MediaPackageV2Channel.md +3 -0
- package/dist/okf/types/MediaPackageV2OriginEndpoint.md +1 -0
- package/dist/okf/types/MediaPipelineKinesisVideoStreamPool.md +28 -0
- package/dist/okf/types/MediaTailorFunction.md +27 -0
- package/dist/okf/types/MedicalVocabulary.md +21 -0
- package/dist/okf/types/Member.md +26 -0
- package/dist/okf/types/Memory.md +6 -0
- package/dist/okf/types/MemoryDBSnapshot.md +29 -0
- package/dist/okf/types/Metric.md +59 -0
- package/dist/okf/types/MetricAttribution.md +23 -0
- package/dist/okf/types/MicrosoftAD.md +11 -11
- package/dist/okf/types/MigrationProject.md +8 -1
- package/dist/okf/types/Monitor.md +26 -0
- package/dist/okf/types/NFSFileShare.md +44 -0
- package/dist/okf/types/NeptuneGraphGraph.md +1 -0
- package/dist/okf/types/NetworkConnector.md +4 -0
- package/dist/okf/types/NetworkFlowMonitorScope.md +23 -0
- package/dist/okf/types/NetworkMigrationDefinition.md +31 -0
- package/dist/okf/types/NetworkSecurityManagerDeployment.md +31 -0
- package/dist/okf/types/NetworkSecurityManagerPolicy.md +32 -0
- package/dist/okf/types/NetworkSecurityManagerScope.md +29 -0
- package/dist/okf/types/NotebookInstance.md +18 -18
- package/dist/okf/types/NotebookInstanceLifecycleConfig.md +6 -5
- package/dist/okf/types/NotifyConfiguration.md +35 -0
- package/dist/okf/types/OTelEnrichment.md +2 -0
- package/dist/okf/types/OnlineEvaluationConfig.md +0 -1
- package/dist/okf/types/OrganizationConfigRule.md +7 -7
- package/dist/okf/types/Outpost.md +32 -0
- package/dist/okf/types/ParallelData.md +40 -0
- package/dist/okf/types/Partition.md +5 -5
- package/dist/okf/types/PaymentConnector.md +4 -1
- package/dist/okf/types/Pentest.md +1 -0
- package/dist/okf/types/PerfReports.md +28 -0
- package/dist/okf/types/PermissionAssociation.md +30 -0
- package/dist/okf/types/PersonalizeDataset.md +1 -0
- package/dist/okf/types/PersonalizeDatasetGroup.md +1 -0
- package/dist/okf/types/PersonalizeSchema.md +1 -0
- package/dist/okf/types/Pipeline.md +25 -0
- package/dist/okf/types/PlaybackConfiguration.md +1 -0
- package/dist/okf/types/PolicyAssociation.md +1 -1
- package/dist/okf/types/PolicyGrant.md +2 -2
- package/dist/okf/types/PolicyPrincipalAttachment.md +2 -7
- package/dist/okf/types/PortalProduct.md +24 -0
- package/dist/okf/types/PrefetchSchedule.md +25 -0
- package/dist/okf/types/PricingPlanManagerSubscription.md +31 -0
- package/dist/okf/types/PrincipalAssociation.md +27 -0
- package/dist/okf/types/PrivateDnsNamespace.md +8 -8
- package/dist/okf/types/PrivateVirtualInterface.md +1 -0
- package/dist/okf/types/ProcurementPortalPreference.md +45 -0
- package/dist/okf/types/Program.md +33 -0
- package/dist/okf/types/ProjectMembership.md +1 -1
- package/dist/okf/types/ProtocolsList.md +26 -0
- package/dist/okf/types/PublicDnsNamespace.md +7 -7
- package/dist/okf/types/PublicVirtualInterface.md +1 -0
- package/dist/okf/types/QEV2IdcApplication.md +25 -0
- package/dist/okf/types/QueryLoggingConfig.md +21 -0
- package/dist/okf/types/QuerySuggestionsBlockList.md +25 -0
- package/dist/okf/types/QuickSightAssignment.md +24 -0
- package/dist/okf/types/RAMResourceAssociation.md +27 -0
- package/dist/okf/types/RDSClusterSnapshot.md +54 -0
- package/dist/okf/types/RDSDBParameterGroup.md +5 -0
- package/dist/okf/types/RDSDeployment.md +41 -0
- package/dist/okf/types/RcsAgent.md +38 -0
- package/dist/okf/types/ReceiptRule.md +5 -5
- package/dist/okf/types/ReceiptRuleSet.md +1 -6
- package/dist/okf/types/RecommenderFilter.md +27 -0
- package/dist/okf/types/RecommenderSchema.md +25 -0
- package/dist/okf/types/RecordSet.md +16 -22
- package/dist/okf/types/RecoveryPlan.md +28 -0
- package/dist/okf/types/RedshiftIdcApplication.md +31 -0
- package/dist/okf/types/RedshiftSnapshot.md +59 -0
- package/dist/okf/types/RegistrationAttachment.md +28 -0
- package/dist/okf/types/Registry.md +41 -0
- package/dist/okf/types/RegistryRecord.md +38 -0
- package/dist/okf/types/RelatedItem.md +24 -0
- package/dist/okf/types/ReplicationConfigurationTemplate.md +35 -0
- package/dist/okf/types/ReplicationSubnetGroup.md +4 -9
- package/dist/okf/types/ReplicationTask.md +14 -14
- package/dist/okf/types/ReportGenerator.md +29 -0
- package/dist/okf/types/ReportGroup.md +1 -3
- package/dist/okf/types/ResilienceHubV2Policy.md +1 -0
- package/dist/okf/types/ResilienceHubV2Service.md +1 -0
- package/dist/okf/types/ResourceConfiguration.md +1 -1
- package/dist/okf/types/ResourceMetricsConfiguration.md +21 -0
- package/dist/okf/types/RestApi.md +1 -0
- package/dist/okf/types/RetrievalInstruction.md +32 -0
- package/dist/okf/types/RouterOutput.md +1 -0
- package/dist/okf/types/Rule.md +31 -0
- package/dist/okf/types/RunCache.md +29 -0
- package/dist/okf/types/Runtime.md +2 -1
- package/dist/okf/types/SCNInstance.md +33 -0
- package/dist/okf/types/SDBDomain.md +2 -2
- package/dist/okf/types/SMBFileShare.md +49 -0
- package/dist/okf/types/SageMakerArtifact.md +27 -0
- package/dist/okf/types/SageMakerEndpoint.md +0 -1
- package/dist/okf/types/ScalableTarget.md +1 -0
- package/dist/okf/types/ScalingPlan.md +6 -6
- package/dist/okf/types/ScheduledReport.md +31 -0
- package/dist/okf/types/SecondaryNetwork.md +26 -0
- package/dist/okf/types/SecurityAgentArtifact.md +25 -0
- package/dist/okf/types/SecurityAgentIntegration.md +31 -0
- package/dist/okf/types/Server.md +1 -0
- package/dist/okf/types/ServerlessCache.md +2 -0
- package/dist/okf/types/ServerlessCacheSnapshot.md +31 -0
- package/dist/okf/types/ServerlessRepoApplication.md +32 -0
- package/dist/okf/types/ServiceDiscoveryInstance.md +3 -7
- package/dist/okf/types/SipMediaApplication.md +27 -0
- package/dist/okf/types/SiteToSiteVpnAttachment.md +2 -0
- package/dist/okf/types/SnapshotCopyGrant.md +20 -0
- package/dist/okf/types/Solution.md +1 -0
- package/dist/okf/types/SourceAssociation.md +25 -0
- package/dist/okf/types/SourceCredential.md +6 -6
- package/dist/okf/types/SourceNetwork.md +23 -0
- package/dist/okf/types/StackFleetAssociation.md +2 -7
- package/dist/okf/types/StorageTierPolicy.md +20 -0
- package/dist/okf/types/StorageVirtualMachine.md +9 -9
- package/dist/okf/types/Stream.md +28 -0
- package/dist/okf/types/SubnetCidrReservation.md +26 -0
- package/dist/okf/types/SubscriptionProvider.md +26 -0
- package/dist/okf/types/SupportPermit.md +29 -0
- package/dist/okf/types/Table.md +2 -1
- package/dist/okf/types/TableOptimizer.md +5 -10
- package/dist/okf/types/Tape.md +31 -0
- package/dist/okf/types/Template.md +36 -0
- package/dist/okf/types/Tenant.md +2 -0
- package/dist/okf/types/Terminology.md +39 -0
- package/dist/okf/types/Thesaurus.md +25 -0
- package/dist/okf/types/ThingPrincipalAttachment.md +3 -8
- package/dist/okf/types/Topic.md +1 -0
- package/dist/okf/types/TopicRuleDestination.md +1 -0
- package/dist/okf/types/TrafficPolicy.md +26 -0
- package/dist/okf/types/TrafficPolicyInstance.md +28 -0
- package/dist/okf/types/TranscribeVocabulary.md +27 -0
- package/dist/okf/types/TransitGatewayRouteTableAttachment.md +2 -0
- package/dist/okf/types/TransitVirtualInterface.md +1 -0
- package/dist/okf/types/Tunnel.md +25 -0
- package/dist/okf/types/UsageLimit.md +26 -0
- package/dist/okf/types/UseCase.md +23 -0
- package/dist/okf/types/User.md +47 -0
- package/dist/okf/types/VPCEndpoint.md +1 -1
- package/dist/okf/types/VPCEndpointService.md +6 -0
- package/dist/okf/types/VPCPeeringConnection.md +2 -2
- package/dist/okf/types/VPNConcentrator.md +1 -1
- package/dist/okf/types/VPNConnection.md +1 -1
- package/dist/okf/types/VerifiedDestinationNumber.md +25 -0
- package/dist/okf/types/View.md +27 -0
- package/dist/okf/types/VoiceConnector.md +30 -0
- package/dist/okf/types/Volume.md +44 -0
- package/dist/okf/types/Vpc.md +1 -1
- package/dist/okf/types/VpcAttachment.md +2 -0
- package/dist/okf/types/WebFunction.md +27 -0
- package/dist/okf/types/WebFunctionEndpoint.md +44 -0
- package/dist/okf/types/WebFunctionRevision.md +32 -0
- package/dist/okf/types/WickrNetwork.md +27 -0
- package/dist/okf/types/Worker.md +29 -0
- package/dist/okf/types/Workforce.md +26 -0
- package/dist/okf/types/Workload.md +35 -0
- package/dist/okf/types/WorkloadEstimate.md +35 -0
- package/dist/okf/types/Workspace.md +28 -0
- package/dist/okf/types/Workteam.md +8 -8
- package/dist/op/activities/aws-apply.js +214 -0
- package/dist/op/activities/floci.js +97 -0
- package/dist/op/activities/index.js +32 -0
- package/dist/op/builders.js +50 -0
- package/dist/ownership.js +52 -0
- package/dist/package-cli.js +25 -0
- package/dist/parameter.js +19 -0
- package/dist/plugin.d.ts.map +1 -1
- package/dist/plugin.js +1006 -0
- package/dist/properties.js +166 -0
- package/dist/pseudo.js +25 -0
- package/dist/receipt-store.d.ts.map +1 -1
- package/dist/receipt-store.js +233 -0
- package/dist/reference-catalog.js +106 -0
- package/dist/rules/ext001.ts +3 -3
- package/dist/rules/waw016.ts +2 -2
- package/dist/serializer.js +529 -0
- package/dist/spec/fetch.js +193 -0
- package/dist/spec/parse.js +259 -0
- package/dist/spec/pin.js +185 -0
- package/dist/spec/pinned-types.json +203 -0
- package/dist/stack-errors.js +14 -0
- package/dist/taggable.d.ts.map +1 -1
- package/dist/taggable.js +33 -0
- package/dist/teardown.js +199 -0
- package/dist/template-sections.js +53 -0
- package/dist/template-transform.js +50 -0
- package/dist/types/index.d.ts +18847 -1124
- package/dist/validate-cli.js +16 -0
- package/dist/validate.js +33 -0
- package/package.json +9 -9
- package/src/agentcore/trace-fetch.ts +2 -1
- package/src/api/credential-chain.ts +119 -9
- package/src/api/credential-isolation.test.ts +72 -0
- package/src/api/read-client-chain.test.ts +159 -0
- package/src/api/read-client.ts +42 -6
- package/src/api/sigv4.ts +4 -4
- package/src/caller-identity.ts +3 -5
- package/src/codegen/any-budget.test.ts +12 -2
- package/src/codegen/generate.ts +9 -0
- package/src/codegen/package.ts +2 -2
- package/src/codegen/patches.test.ts +95 -0
- package/src/codegen/patches.ts +53 -9
- package/src/codegen/property-overlay.json +1 -16
- package/src/components/apply.ts +218 -6
- package/src/components/cfn-plan-floci.e2e.test.ts +76 -0
- package/src/components/cfn-plan.test.ts +225 -16
- package/src/components/cloud-executor.ts +73 -25
- package/src/deep-observe.ts +2 -1
- package/src/disruption.ts +2 -1
- package/src/generated/index.d.ts +18847 -1124
- package/src/generated/index.ts +1376 -161
- package/src/generated/lexicon-aws.json +17359 -784
- package/src/identity-observe.ts +2 -1
- package/src/lint/post-synth/ext001.ts +3 -3
- package/src/lint/post-synth/waw016.ts +2 -2
- package/src/lsp/completions.ts +2 -1
- package/src/lsp/hover.ts +2 -1
- package/src/plugin.ts +2 -1
- package/src/receipt-store.ts +2 -1
- package/src/spec/pin.ts +3 -3
- package/src/spec/pinned-types.json +203 -0
- package/src/taggable.ts +2 -2
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* WAW023: CloudFront Without WAF
|
|
3
|
+
*
|
|
4
|
+
* Flags CloudFront distributions without WebACLId.
|
|
5
|
+
*/
|
|
6
|
+
import { parseCFTemplate } from "./cf-refs.js";
|
|
7
|
+
export function checkCloudFrontWaf(ctx) {
|
|
8
|
+
const diagnostics = [];
|
|
9
|
+
for (const [_lexicon, output] of ctx.outputs) {
|
|
10
|
+
const template = parseCFTemplate(output);
|
|
11
|
+
if (!template?.Resources)
|
|
12
|
+
continue;
|
|
13
|
+
for (const [logicalId, resource] of Object.entries(template.Resources)) {
|
|
14
|
+
if (resource.Type !== "AWS::CloudFront::Distribution")
|
|
15
|
+
continue;
|
|
16
|
+
const props = resource.Properties ?? {};
|
|
17
|
+
const distConfig = props.DistributionConfig;
|
|
18
|
+
if (typeof distConfig !== "object" || distConfig === null)
|
|
19
|
+
continue;
|
|
20
|
+
const config = distConfig;
|
|
21
|
+
if (!("WebACLId" in config)) {
|
|
22
|
+
diagnostics.push({
|
|
23
|
+
checkId: "WAW023",
|
|
24
|
+
severity: "warning",
|
|
25
|
+
message: `CloudFront distribution "${logicalId}" has no WebACLId — consider attaching a WAF web ACL for protection`,
|
|
26
|
+
entity: logicalId,
|
|
27
|
+
lexicon: "aws",
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
return diagnostics;
|
|
33
|
+
}
|
|
34
|
+
export const waw023 = {
|
|
35
|
+
id: "WAW023",
|
|
36
|
+
description: "CloudFront distribution has no WAF web ACL — consider attaching one for protection",
|
|
37
|
+
check(ctx) {
|
|
38
|
+
return checkCloudFrontWaf(ctx);
|
|
39
|
+
},
|
|
40
|
+
};
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* WAW024: ALB Without Access Logging
|
|
3
|
+
*
|
|
4
|
+
* Flags Application Load Balancers without access logging enabled.
|
|
5
|
+
*/
|
|
6
|
+
import { parseCFTemplate } from "./cf-refs.js";
|
|
7
|
+
export function checkAlbAccessLogs(ctx) {
|
|
8
|
+
const diagnostics = [];
|
|
9
|
+
for (const [_lexicon, output] of ctx.outputs) {
|
|
10
|
+
const template = parseCFTemplate(output);
|
|
11
|
+
if (!template?.Resources)
|
|
12
|
+
continue;
|
|
13
|
+
for (const [logicalId, resource] of Object.entries(template.Resources)) {
|
|
14
|
+
if (resource.Type !== "AWS::ElasticLoadBalancingV2::LoadBalancer")
|
|
15
|
+
continue;
|
|
16
|
+
const props = resource.Properties ?? {};
|
|
17
|
+
const attrs = props.LoadBalancerAttributes;
|
|
18
|
+
let hasAccessLogs = false;
|
|
19
|
+
if (Array.isArray(attrs)) {
|
|
20
|
+
hasAccessLogs = attrs.some((attr) => {
|
|
21
|
+
if (typeof attr !== "object" || attr === null)
|
|
22
|
+
return false;
|
|
23
|
+
const a = attr;
|
|
24
|
+
return a.Key === "access_logs.s3.enabled" && (a.Value === "true" || a.Value === true);
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
if (!hasAccessLogs) {
|
|
28
|
+
diagnostics.push({
|
|
29
|
+
checkId: "WAW024",
|
|
30
|
+
severity: "warning",
|
|
31
|
+
message: `Load balancer "${logicalId}" does not have access logging enabled — enable access_logs.s3.enabled for audit trails`,
|
|
32
|
+
entity: logicalId,
|
|
33
|
+
lexicon: "aws",
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
return diagnostics;
|
|
39
|
+
}
|
|
40
|
+
export const waw024 = {
|
|
41
|
+
id: "WAW024",
|
|
42
|
+
description: "Application Load Balancer does not have access logging enabled",
|
|
43
|
+
check(ctx) {
|
|
44
|
+
return checkAlbAccessLogs(ctx);
|
|
45
|
+
},
|
|
46
|
+
};
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* WAW025: SNS Topic Not Encrypted
|
|
3
|
+
*
|
|
4
|
+
* Flags SNS topics without KmsMasterKeyId.
|
|
5
|
+
*/
|
|
6
|
+
import { parseCFTemplate } from "./cf-refs.js";
|
|
7
|
+
export function checkSnsEncryption(ctx) {
|
|
8
|
+
const diagnostics = [];
|
|
9
|
+
for (const [_lexicon, output] of ctx.outputs) {
|
|
10
|
+
const template = parseCFTemplate(output);
|
|
11
|
+
if (!template?.Resources)
|
|
12
|
+
continue;
|
|
13
|
+
for (const [logicalId, resource] of Object.entries(template.Resources)) {
|
|
14
|
+
if (resource.Type !== "AWS::SNS::Topic")
|
|
15
|
+
continue;
|
|
16
|
+
const props = resource.Properties ?? {};
|
|
17
|
+
if (!("KmsMasterKeyId" in props)) {
|
|
18
|
+
diagnostics.push({
|
|
19
|
+
checkId: "WAW025",
|
|
20
|
+
severity: "warning",
|
|
21
|
+
message: `SNS topic "${logicalId}" is not encrypted — add KmsMasterKeyId for encryption at rest`,
|
|
22
|
+
entity: logicalId,
|
|
23
|
+
lexicon: "aws",
|
|
24
|
+
});
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
return diagnostics;
|
|
29
|
+
}
|
|
30
|
+
export const waw025 = {
|
|
31
|
+
id: "WAW025",
|
|
32
|
+
description: "SNS topic is not encrypted — add KmsMasterKeyId for encryption at rest",
|
|
33
|
+
check(ctx) {
|
|
34
|
+
return checkSnsEncryption(ctx);
|
|
35
|
+
},
|
|
36
|
+
};
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* WAW026: SQS Queue Not Encrypted
|
|
3
|
+
*
|
|
4
|
+
* Flags SQS queues without SqsManagedSseEnabled or KmsMasterKeyId.
|
|
5
|
+
*/
|
|
6
|
+
import { parseCFTemplate } from "./cf-refs.js";
|
|
7
|
+
export function checkSqsEncryption(ctx) {
|
|
8
|
+
const diagnostics = [];
|
|
9
|
+
for (const [_lexicon, output] of ctx.outputs) {
|
|
10
|
+
const template = parseCFTemplate(output);
|
|
11
|
+
if (!template?.Resources)
|
|
12
|
+
continue;
|
|
13
|
+
for (const [logicalId, resource] of Object.entries(template.Resources)) {
|
|
14
|
+
if (resource.Type !== "AWS::SQS::Queue")
|
|
15
|
+
continue;
|
|
16
|
+
const props = resource.Properties ?? {};
|
|
17
|
+
const hasSseSqs = props.SqsManagedSseEnabled === true;
|
|
18
|
+
const hasKms = "KmsMasterKeyId" in props;
|
|
19
|
+
if (!hasSseSqs && !hasKms) {
|
|
20
|
+
diagnostics.push({
|
|
21
|
+
checkId: "WAW026",
|
|
22
|
+
severity: "warning",
|
|
23
|
+
message: `SQS queue "${logicalId}" is not encrypted — enable SqsManagedSseEnabled or set KmsMasterKeyId`,
|
|
24
|
+
entity: logicalId,
|
|
25
|
+
lexicon: "aws",
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
return diagnostics;
|
|
31
|
+
}
|
|
32
|
+
export const waw026 = {
|
|
33
|
+
id: "WAW026",
|
|
34
|
+
description: "SQS queue is not encrypted — enable SqsManagedSseEnabled or set KmsMasterKeyId",
|
|
35
|
+
check(ctx) {
|
|
36
|
+
return checkSqsEncryption(ctx);
|
|
37
|
+
},
|
|
38
|
+
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* WAW027: DynamoDB Missing Point-in-Time Recovery
|
|
3
|
+
*
|
|
4
|
+
* Flags DynamoDB tables without PointInTimeRecoverySpecification.PointInTimeRecoveryEnabled.
|
|
5
|
+
*/
|
|
6
|
+
import { parseCFTemplate } from "./cf-refs.js";
|
|
7
|
+
export function checkDynamoDbPitr(ctx) {
|
|
8
|
+
const diagnostics = [];
|
|
9
|
+
for (const [_lexicon, output] of ctx.outputs) {
|
|
10
|
+
const template = parseCFTemplate(output);
|
|
11
|
+
if (!template?.Resources)
|
|
12
|
+
continue;
|
|
13
|
+
for (const [logicalId, resource] of Object.entries(template.Resources)) {
|
|
14
|
+
if (resource.Type !== "AWS::DynamoDB::Table")
|
|
15
|
+
continue;
|
|
16
|
+
const props = resource.Properties ?? {};
|
|
17
|
+
const pitrSpec = props.PointInTimeRecoverySpecification;
|
|
18
|
+
let pitrEnabled = false;
|
|
19
|
+
if (typeof pitrSpec === "object" && pitrSpec !== null) {
|
|
20
|
+
pitrEnabled = pitrSpec.PointInTimeRecoveryEnabled === true;
|
|
21
|
+
}
|
|
22
|
+
if (!pitrEnabled) {
|
|
23
|
+
diagnostics.push({
|
|
24
|
+
checkId: "WAW027",
|
|
25
|
+
severity: "info",
|
|
26
|
+
message: `DynamoDB table "${logicalId}" does not have point-in-time recovery enabled — consider enabling for data protection`,
|
|
27
|
+
entity: logicalId,
|
|
28
|
+
lexicon: "aws",
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
return diagnostics;
|
|
34
|
+
}
|
|
35
|
+
export const waw027 = {
|
|
36
|
+
id: "WAW027",
|
|
37
|
+
description: "DynamoDB table does not have point-in-time recovery enabled",
|
|
38
|
+
check(ctx) {
|
|
39
|
+
return checkDynamoDbPitr(ctx);
|
|
40
|
+
},
|
|
41
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* WAW028: EBS Volume Not Encrypted
|
|
3
|
+
*
|
|
4
|
+
* Flags EBS volumes without Encrypted: true.
|
|
5
|
+
*/
|
|
6
|
+
import { parseCFTemplate, isIntrinsic } from "./cf-refs.js";
|
|
7
|
+
export function checkEbsEncryption(ctx) {
|
|
8
|
+
const diagnostics = [];
|
|
9
|
+
for (const [_lexicon, output] of ctx.outputs) {
|
|
10
|
+
const template = parseCFTemplate(output);
|
|
11
|
+
if (!template?.Resources)
|
|
12
|
+
continue;
|
|
13
|
+
for (const [logicalId, resource] of Object.entries(template.Resources)) {
|
|
14
|
+
if (resource.Type !== "AWS::EC2::Volume")
|
|
15
|
+
continue;
|
|
16
|
+
const props = resource.Properties ?? {};
|
|
17
|
+
const encrypted = props.Encrypted;
|
|
18
|
+
if (isIntrinsic(encrypted))
|
|
19
|
+
continue;
|
|
20
|
+
if (encrypted !== true) {
|
|
21
|
+
diagnostics.push({
|
|
22
|
+
checkId: "WAW028",
|
|
23
|
+
severity: "warning",
|
|
24
|
+
message: `EBS volume "${logicalId}" does not have Encrypted: true — enable encryption at rest`,
|
|
25
|
+
entity: logicalId,
|
|
26
|
+
lexicon: "aws",
|
|
27
|
+
});
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
return diagnostics;
|
|
32
|
+
}
|
|
33
|
+
export const waw028 = {
|
|
34
|
+
id: "WAW028",
|
|
35
|
+
description: "EBS volume is not encrypted — enable encryption at rest",
|
|
36
|
+
check(ctx) {
|
|
37
|
+
return checkEbsEncryption(ctx);
|
|
38
|
+
},
|
|
39
|
+
};
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* WAW029: Invalid DependsOn Target
|
|
3
|
+
*
|
|
4
|
+
* Detects two cases in the serialized template:
|
|
5
|
+
* - Dangling reference: DependsOn target not in template.Resources
|
|
6
|
+
* - Self-reference: Resource depends on itself
|
|
7
|
+
*/
|
|
8
|
+
import { parseCFTemplate } from "./cf-refs.js";
|
|
9
|
+
export function checkInvalidDependsOn(ctx) {
|
|
10
|
+
const diagnostics = [];
|
|
11
|
+
for (const [_lexicon, output] of ctx.outputs) {
|
|
12
|
+
const template = parseCFTemplate(output);
|
|
13
|
+
if (!template?.Resources)
|
|
14
|
+
continue;
|
|
15
|
+
const resourceIds = new Set(Object.keys(template.Resources));
|
|
16
|
+
for (const [logicalId, resource] of Object.entries(template.Resources)) {
|
|
17
|
+
if (!resource.DependsOn)
|
|
18
|
+
continue;
|
|
19
|
+
const deps = Array.isArray(resource.DependsOn)
|
|
20
|
+
? resource.DependsOn
|
|
21
|
+
: [resource.DependsOn];
|
|
22
|
+
for (const dep of deps) {
|
|
23
|
+
if (typeof dep !== "string")
|
|
24
|
+
continue;
|
|
25
|
+
if (dep === logicalId) {
|
|
26
|
+
diagnostics.push({
|
|
27
|
+
checkId: "WAW029",
|
|
28
|
+
severity: "error",
|
|
29
|
+
message: `Resource "${logicalId}" has a DependsOn on itself — self-references are invalid`,
|
|
30
|
+
entity: logicalId,
|
|
31
|
+
lexicon: "aws",
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
else if (!resourceIds.has(dep)) {
|
|
35
|
+
diagnostics.push({
|
|
36
|
+
checkId: "WAW029",
|
|
37
|
+
severity: "error",
|
|
38
|
+
message: `Resource "${logicalId}" has DependsOn "${dep}" which does not exist in the template`,
|
|
39
|
+
entity: logicalId,
|
|
40
|
+
lexicon: "aws",
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
return diagnostics;
|
|
47
|
+
}
|
|
48
|
+
export const waw029 = {
|
|
49
|
+
id: "WAW029",
|
|
50
|
+
description: "Invalid DependsOn target — dangling reference or self-reference",
|
|
51
|
+
check(ctx) {
|
|
52
|
+
return checkInvalidDependsOn(ctx);
|
|
53
|
+
},
|
|
54
|
+
};
|
|
@@ -0,0 +1,282 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* WAW030: Missing DependsOn for Known Patterns
|
|
3
|
+
*
|
|
4
|
+
* Detects resources that are likely missing a required DependsOn
|
|
5
|
+
* based on well-known CloudFormation ordering requirements:
|
|
6
|
+
*
|
|
7
|
+
* - ECS Service with LoadBalancers but no DependsOn on a Listener
|
|
8
|
+
* - EC2 Route with GatewayId but no DependsOn on VPCGatewayAttachment
|
|
9
|
+
* - API Gateway Deployment with no DependsOn on any Method
|
|
10
|
+
* - API Gateway V2 Deployment with no DependsOn on any Route
|
|
11
|
+
* - DynamoDB ScalableTarget with no DependsOn on the Table
|
|
12
|
+
* - ECS ScalableTarget with no DependsOn on the ECS Service
|
|
13
|
+
* - EKS Addon with hardcoded ClusterName but no DependsOn on the Cluster or Nodegroup
|
|
14
|
+
* - EKS Nodegroup with hardcoded ClusterName but no DependsOn on the Cluster
|
|
15
|
+
*/
|
|
16
|
+
import { parseCFTemplate } from "./cf-refs.js";
|
|
17
|
+
export function checkMissingDependsOn(ctx) {
|
|
18
|
+
const diagnostics = [];
|
|
19
|
+
for (const [_lexicon, output] of ctx.outputs) {
|
|
20
|
+
const template = parseCFTemplate(output);
|
|
21
|
+
if (!template?.Resources)
|
|
22
|
+
continue;
|
|
23
|
+
const resources = template.Resources;
|
|
24
|
+
// Collect logical IDs by type
|
|
25
|
+
const listenerIds = [];
|
|
26
|
+
const vpcGatewayAttachmentIds = [];
|
|
27
|
+
const methodIds = [];
|
|
28
|
+
const deploymentIds = [];
|
|
29
|
+
const routeV2Ids = [];
|
|
30
|
+
const deploymentV2Ids = [];
|
|
31
|
+
const dynamoTableIds = [];
|
|
32
|
+
const ecsServiceIds = [];
|
|
33
|
+
const scalableTargetEntries = [];
|
|
34
|
+
const eksClusterIds = [];
|
|
35
|
+
const eksNodegroupIds = [];
|
|
36
|
+
const eksAddonIds = [];
|
|
37
|
+
for (const [logicalId, resource] of Object.entries(resources)) {
|
|
38
|
+
if (resource.Type === "AWS::ElasticLoadBalancingV2::Listener") {
|
|
39
|
+
listenerIds.push(logicalId);
|
|
40
|
+
}
|
|
41
|
+
if (resource.Type === "AWS::EC2::VPCGatewayAttachment") {
|
|
42
|
+
vpcGatewayAttachmentIds.push(logicalId);
|
|
43
|
+
}
|
|
44
|
+
if (resource.Type === "AWS::ApiGateway::Method") {
|
|
45
|
+
methodIds.push(logicalId);
|
|
46
|
+
}
|
|
47
|
+
if (resource.Type === "AWS::ApiGateway::Deployment") {
|
|
48
|
+
deploymentIds.push(logicalId);
|
|
49
|
+
}
|
|
50
|
+
if (resource.Type === "AWS::ApiGatewayV2::Route") {
|
|
51
|
+
routeV2Ids.push(logicalId);
|
|
52
|
+
}
|
|
53
|
+
if (resource.Type === "AWS::ApiGatewayV2::Deployment") {
|
|
54
|
+
deploymentV2Ids.push(logicalId);
|
|
55
|
+
}
|
|
56
|
+
if (resource.Type === "AWS::DynamoDB::Table") {
|
|
57
|
+
dynamoTableIds.push(logicalId);
|
|
58
|
+
}
|
|
59
|
+
if (resource.Type === "AWS::ECS::Service") {
|
|
60
|
+
ecsServiceIds.push(logicalId);
|
|
61
|
+
}
|
|
62
|
+
if (resource.Type === "AWS::EKS::Cluster") {
|
|
63
|
+
eksClusterIds.push(logicalId);
|
|
64
|
+
}
|
|
65
|
+
if (resource.Type === "AWS::EKS::Nodegroup") {
|
|
66
|
+
eksNodegroupIds.push(logicalId);
|
|
67
|
+
}
|
|
68
|
+
if (resource.Type === "AWS::EKS::Addon") {
|
|
69
|
+
eksAddonIds.push(logicalId);
|
|
70
|
+
}
|
|
71
|
+
if (resource.Type === "AWS::ApplicationAutoScaling::ScalableTarget") {
|
|
72
|
+
const props = resource.Properties ?? {};
|
|
73
|
+
const ns = inferScalingNamespace(props);
|
|
74
|
+
if (ns) {
|
|
75
|
+
scalableTargetEntries.push({ logicalId, namespace: ns });
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
for (const [logicalId, resource] of Object.entries(resources)) {
|
|
80
|
+
// Pattern 1: ECS Service with LoadBalancers but no DependsOn on Listener
|
|
81
|
+
if (resource.Type === "AWS::ECS::Service" && listenerIds.length > 0) {
|
|
82
|
+
const props = resource.Properties ?? {};
|
|
83
|
+
if (props.LoadBalancers && Array.isArray(props.LoadBalancers) && props.LoadBalancers.length > 0) {
|
|
84
|
+
const deps = getDependsOnSet(resource);
|
|
85
|
+
const hasListenerDep = listenerIds.some((id) => deps.has(id));
|
|
86
|
+
if (!hasListenerDep) {
|
|
87
|
+
diagnostics.push({
|
|
88
|
+
checkId: "WAW030",
|
|
89
|
+
severity: "warning",
|
|
90
|
+
message: `ECS Service "${logicalId}" has LoadBalancers but no DependsOn on a Listener — the Service may fail to create if the Listener isn't ready`,
|
|
91
|
+
entity: logicalId,
|
|
92
|
+
lexicon: "aws",
|
|
93
|
+
});
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
// Pattern 2: EC2 Route with GatewayId but no DependsOn on VPCGatewayAttachment
|
|
98
|
+
if (resource.Type === "AWS::EC2::Route" && vpcGatewayAttachmentIds.length > 0) {
|
|
99
|
+
const props = resource.Properties ?? {};
|
|
100
|
+
if (props.GatewayId) {
|
|
101
|
+
const deps = getDependsOnSet(resource);
|
|
102
|
+
const hasAttachmentDep = vpcGatewayAttachmentIds.some((id) => deps.has(id));
|
|
103
|
+
// Also check if any property refs point to the attachment
|
|
104
|
+
const propRefs = collectPropertyRefs(resource);
|
|
105
|
+
const hasAttachmentRef = vpcGatewayAttachmentIds.some((id) => propRefs.has(id));
|
|
106
|
+
if (!hasAttachmentDep && !hasAttachmentRef) {
|
|
107
|
+
diagnostics.push({
|
|
108
|
+
checkId: "WAW030",
|
|
109
|
+
severity: "warning",
|
|
110
|
+
message: `Route "${logicalId}" uses a Gateway but has no dependency on VPCGatewayAttachment — the route may fail if the gateway isn't attached yet`,
|
|
111
|
+
entity: logicalId,
|
|
112
|
+
lexicon: "aws",
|
|
113
|
+
});
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
// Pattern 3: API Gateway Deployment with no DependsOn on any Method
|
|
118
|
+
if (resource.Type === "AWS::ApiGateway::Deployment" && methodIds.length > 0) {
|
|
119
|
+
const deps = getDependsOnSet(resource);
|
|
120
|
+
const hasMethodDep = methodIds.some((id) => deps.has(id));
|
|
121
|
+
const propRefs = collectPropertyRefs(resource);
|
|
122
|
+
const hasMethodRef = methodIds.some((id) => propRefs.has(id));
|
|
123
|
+
if (!hasMethodDep && !hasMethodRef) {
|
|
124
|
+
diagnostics.push({
|
|
125
|
+
checkId: "WAW030",
|
|
126
|
+
severity: "warning",
|
|
127
|
+
message: `API Gateway Deployment "${logicalId}" has no DependsOn on any Method — the deployment may fail with "REST API doesn't contain any methods"`,
|
|
128
|
+
entity: logicalId,
|
|
129
|
+
lexicon: "aws",
|
|
130
|
+
});
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
// Pattern 4: API Gateway V2 Deployment with no DependsOn on any Route
|
|
134
|
+
if (resource.Type === "AWS::ApiGatewayV2::Deployment" && routeV2Ids.length > 0) {
|
|
135
|
+
const deps = getDependsOnSet(resource);
|
|
136
|
+
const hasRouteDep = routeV2Ids.some((id) => deps.has(id));
|
|
137
|
+
const propRefs = collectPropertyRefs(resource);
|
|
138
|
+
const hasRouteRef = routeV2Ids.some((id) => propRefs.has(id));
|
|
139
|
+
if (!hasRouteDep && !hasRouteRef) {
|
|
140
|
+
diagnostics.push({
|
|
141
|
+
checkId: "WAW030",
|
|
142
|
+
severity: "warning",
|
|
143
|
+
message: `API Gateway V2 Deployment "${logicalId}" has no DependsOn on any Route — the deployment may fail if no routes exist yet`,
|
|
144
|
+
entity: logicalId,
|
|
145
|
+
lexicon: "aws",
|
|
146
|
+
});
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
// Pattern 7: EKS Addon with hardcoded ClusterName but no dependency on Cluster or Nodegroup
|
|
151
|
+
for (const addonId of eksAddonIds) {
|
|
152
|
+
const resource = resources[addonId];
|
|
153
|
+
const deps = getDependsOnSet(resource);
|
|
154
|
+
const propRefs = collectPropertyRefs(resource);
|
|
155
|
+
const allClusterAndNodeDeps = [...eksClusterIds, ...eksNodegroupIds];
|
|
156
|
+
const hasClusterDep = allClusterAndNodeDeps.some((id) => deps.has(id));
|
|
157
|
+
const hasClusterRef = allClusterAndNodeDeps.some((id) => propRefs.has(id));
|
|
158
|
+
if (!hasClusterDep && !hasClusterRef && eksClusterIds.length > 0) {
|
|
159
|
+
diagnostics.push({
|
|
160
|
+
checkId: "WAW030",
|
|
161
|
+
severity: "warning",
|
|
162
|
+
message: `EKS Addon "${addonId}" has no dependency on the Cluster or Nodegroup — the addon may fail if the cluster or nodes aren't ready yet. Add DependsOn.`,
|
|
163
|
+
entity: addonId,
|
|
164
|
+
lexicon: "aws",
|
|
165
|
+
});
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
// Pattern 8: EKS Nodegroup with hardcoded ClusterName but no dependency on Cluster
|
|
169
|
+
for (const ngId of eksNodegroupIds) {
|
|
170
|
+
const resource = resources[ngId];
|
|
171
|
+
const deps = getDependsOnSet(resource);
|
|
172
|
+
const propRefs = collectPropertyRefs(resource);
|
|
173
|
+
const hasClusterDep = eksClusterIds.some((id) => deps.has(id));
|
|
174
|
+
const hasClusterRef = eksClusterIds.some((id) => propRefs.has(id));
|
|
175
|
+
if (!hasClusterDep && !hasClusterRef && eksClusterIds.length > 0) {
|
|
176
|
+
diagnostics.push({
|
|
177
|
+
checkId: "WAW030",
|
|
178
|
+
severity: "warning",
|
|
179
|
+
message: `EKS Nodegroup "${ngId}" has no dependency on the Cluster — the node group may fail if the cluster isn't ready yet. Add DependsOn.`,
|
|
180
|
+
entity: ngId,
|
|
181
|
+
lexicon: "aws",
|
|
182
|
+
});
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
// Pattern 5 & 6: ScalableTarget with no DependsOn on the target resource
|
|
186
|
+
for (const entry of scalableTargetEntries) {
|
|
187
|
+
const resource = resources[entry.logicalId];
|
|
188
|
+
const deps = getDependsOnSet(resource);
|
|
189
|
+
const propRefs = collectPropertyRefs(resource);
|
|
190
|
+
if (entry.namespace === "dynamodb" && dynamoTableIds.length > 0) {
|
|
191
|
+
const hasTableDep = dynamoTableIds.some((id) => deps.has(id));
|
|
192
|
+
const hasTableRef = dynamoTableIds.some((id) => propRefs.has(id));
|
|
193
|
+
if (!hasTableDep && !hasTableRef) {
|
|
194
|
+
diagnostics.push({
|
|
195
|
+
checkId: "WAW030",
|
|
196
|
+
severity: "warning",
|
|
197
|
+
message: `ScalableTarget "${entry.logicalId}" targets DynamoDB but has no DependsOn on any Table — scaling registration may fail if the table doesn't exist yet`,
|
|
198
|
+
entity: entry.logicalId,
|
|
199
|
+
lexicon: "aws",
|
|
200
|
+
});
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
if (entry.namespace === "ecs" && ecsServiceIds.length > 0) {
|
|
204
|
+
const hasServiceDep = ecsServiceIds.some((id) => deps.has(id));
|
|
205
|
+
const hasServiceRef = ecsServiceIds.some((id) => propRefs.has(id));
|
|
206
|
+
if (!hasServiceDep && !hasServiceRef) {
|
|
207
|
+
diagnostics.push({
|
|
208
|
+
checkId: "WAW030",
|
|
209
|
+
severity: "warning",
|
|
210
|
+
message: `ScalableTarget "${entry.logicalId}" targets ECS but has no DependsOn on any ECS Service — scaling registration may fail if the service doesn't exist yet`,
|
|
211
|
+
entity: entry.logicalId,
|
|
212
|
+
lexicon: "aws",
|
|
213
|
+
});
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
return diagnostics;
|
|
219
|
+
}
|
|
220
|
+
/** Infer the scaling namespace from a ScalableTarget's properties. */
|
|
221
|
+
function inferScalingNamespace(props) {
|
|
222
|
+
if (typeof props.ServiceNamespace === "string") {
|
|
223
|
+
return props.ServiceNamespace;
|
|
224
|
+
}
|
|
225
|
+
if (typeof props.ScalableDimension === "string") {
|
|
226
|
+
const prefix = props.ScalableDimension.split(":")[0];
|
|
227
|
+
if (prefix)
|
|
228
|
+
return prefix;
|
|
229
|
+
}
|
|
230
|
+
return null;
|
|
231
|
+
}
|
|
232
|
+
/** Extract DependsOn entries as a Set of strings. */
|
|
233
|
+
function getDependsOnSet(resource) {
|
|
234
|
+
if (!resource.DependsOn)
|
|
235
|
+
return new Set();
|
|
236
|
+
const deps = Array.isArray(resource.DependsOn)
|
|
237
|
+
? resource.DependsOn
|
|
238
|
+
: [resource.DependsOn];
|
|
239
|
+
return new Set(deps.filter((d) => typeof d === "string"));
|
|
240
|
+
}
|
|
241
|
+
/** Collect all Ref and Fn::GetAtt target logical IDs from resource properties. */
|
|
242
|
+
function collectPropertyRefs(resource) {
|
|
243
|
+
const refs = new Set();
|
|
244
|
+
if (!resource.Properties)
|
|
245
|
+
return refs;
|
|
246
|
+
function walk(value) {
|
|
247
|
+
if (typeof value !== "object" || value === null)
|
|
248
|
+
return;
|
|
249
|
+
if (Array.isArray(value)) {
|
|
250
|
+
for (const item of value)
|
|
251
|
+
walk(item);
|
|
252
|
+
return;
|
|
253
|
+
}
|
|
254
|
+
const obj = value;
|
|
255
|
+
if ("Ref" in obj && typeof obj.Ref === "string") {
|
|
256
|
+
refs.add(obj.Ref);
|
|
257
|
+
}
|
|
258
|
+
if ("Fn::GetAtt" in obj) {
|
|
259
|
+
const getAtt = obj["Fn::GetAtt"];
|
|
260
|
+
if (Array.isArray(getAtt) && typeof getAtt[0] === "string") {
|
|
261
|
+
refs.add(getAtt[0]);
|
|
262
|
+
}
|
|
263
|
+
else if (typeof getAtt === "string") {
|
|
264
|
+
// Dot-delimited form: "LogicalId.Attribute"
|
|
265
|
+
const logicalId = getAtt.split(".")[0];
|
|
266
|
+
if (logicalId)
|
|
267
|
+
refs.add(logicalId);
|
|
268
|
+
}
|
|
269
|
+
}
|
|
270
|
+
for (const val of Object.values(obj))
|
|
271
|
+
walk(val);
|
|
272
|
+
}
|
|
273
|
+
walk(resource.Properties);
|
|
274
|
+
return refs;
|
|
275
|
+
}
|
|
276
|
+
export const waw030 = {
|
|
277
|
+
id: "WAW030",
|
|
278
|
+
description: "Missing DependsOn for known CloudFormation ordering patterns",
|
|
279
|
+
check(ctx) {
|
|
280
|
+
return checkMissingDependsOn(ctx);
|
|
281
|
+
},
|
|
282
|
+
};
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* WAW031: EKS Addon Missing ServiceAccountRoleArn
|
|
3
|
+
*
|
|
4
|
+
* Certain EKS addons require a ServiceAccountRoleArn (IRSA role) to function.
|
|
5
|
+
* Without one, the addon pods can't authenticate to AWS APIs and the addon
|
|
6
|
+
* hangs in CREATING status indefinitely.
|
|
7
|
+
*
|
|
8
|
+
* Known addons that require IRSA:
|
|
9
|
+
* - aws-ebs-csi-driver (needs EBS API access)
|
|
10
|
+
* - aws-efs-csi-driver (needs EFS API access)
|
|
11
|
+
* - adot (needs CloudWatch/X-Ray access)
|
|
12
|
+
* - amazon-cloudwatch-observability (needs CloudWatch access)
|
|
13
|
+
*/
|
|
14
|
+
import { parseCFTemplate } from "./cf-refs.js";
|
|
15
|
+
/** Addons that are known to require a ServiceAccountRoleArn to function. */
|
|
16
|
+
const ADDONS_REQUIRING_IRSA = {
|
|
17
|
+
"aws-ebs-csi-driver": "EBS API access to manage volumes",
|
|
18
|
+
"aws-efs-csi-driver": "EFS API access to manage file systems",
|
|
19
|
+
"adot": "CloudWatch/X-Ray access for metrics and traces",
|
|
20
|
+
"amazon-cloudwatch-observability": "CloudWatch access for logs and metrics",
|
|
21
|
+
};
|
|
22
|
+
export function checkAddonMissingRole(ctx) {
|
|
23
|
+
const diagnostics = [];
|
|
24
|
+
for (const [_lexicon, output] of ctx.outputs) {
|
|
25
|
+
const template = parseCFTemplate(output);
|
|
26
|
+
if (!template?.Resources)
|
|
27
|
+
continue;
|
|
28
|
+
for (const [logicalId, resource] of Object.entries(template.Resources)) {
|
|
29
|
+
if (resource.Type !== "AWS::EKS::Addon")
|
|
30
|
+
continue;
|
|
31
|
+
const props = resource.Properties ?? {};
|
|
32
|
+
const addonName = typeof props.AddonName === "string" ? props.AddonName : null;
|
|
33
|
+
if (!addonName)
|
|
34
|
+
continue;
|
|
35
|
+
const reason = ADDONS_REQUIRING_IRSA[addonName];
|
|
36
|
+
if (!reason)
|
|
37
|
+
continue;
|
|
38
|
+
// Check if ServiceAccountRoleArn is set (could be a string, Ref, or GetAtt)
|
|
39
|
+
if (!props.ServiceAccountRoleArn) {
|
|
40
|
+
diagnostics.push({
|
|
41
|
+
checkId: "WAW031",
|
|
42
|
+
severity: "warning",
|
|
43
|
+
message: `EKS Addon "${logicalId}" (${addonName}) has no ServiceAccountRoleArn — it needs an IRSA role for ${reason}. Without it, the addon will hang in CREATING status.`,
|
|
44
|
+
entity: logicalId,
|
|
45
|
+
lexicon: "aws",
|
|
46
|
+
});
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
return diagnostics;
|
|
51
|
+
}
|
|
52
|
+
export const waw031 = {
|
|
53
|
+
id: "WAW031",
|
|
54
|
+
description: "EKS Addon missing ServiceAccountRoleArn for addons that require IRSA",
|
|
55
|
+
check(ctx) {
|
|
56
|
+
return checkAddonMissingRole(ctx);
|
|
57
|
+
},
|
|
58
|
+
};
|