File tree Expand file tree Collapse file tree
infrastructure/stacks/iams-developer-roles Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -182,17 +182,23 @@ resource "aws_iam_policy" "api_infrastructure" {
182182 Effect = " Allow" ,
183183 Action = [
184184 " logs:Describe*" ,
185- " logs:PutLogEvents" ,
186- " logs:CreateLogGroup" ,
187- " logs:CreateLogStream" ,
188185 " ssm:DescribeParameters" ,
189186 " ec2:Describe*" ,
190187 " ec2:DescribeVpcs" ,
191- " acm:ListCertificates" ,
188+ # API Gateway domain and deployment
189+ " apigateway:*" ,
190+ # ACM for certs
192191 " acm:DescribeCertificate" ,
193192 " acm:GetCertificate" ,
194- " apigateway:*" ,
195- " iam:PassRole" ,
193+ " acm:ListCertificates" ,
194+ # S3 for mTLS truststore
195+ " s3:GetObject" ,
196+ # CloudWatch Logs for logging
197+ " logs:CreateLogGroup" ,
198+ " logs:CreateLogStream" ,
199+ " logs:PutLogEvents" ,
200+ # IAM PassRole for logging role association (if needed)
201+ " iam:PassRole"
196202 ],
197203 Resource = " *"
198204 # checkov:skip=CKV_AWS_289: Actions require wildcard resource
@@ -258,7 +264,7 @@ resource "aws_iam_policy" "api_infrastructure" {
258264 " arn:aws:ssm:${ var . default_aws_region } :${ data . aws_caller_identity . current . account_id } :parameter/${ var . environment } /*" ,
259265 " arn:aws:acm:${ var . default_aws_region } :${ data . aws_caller_identity . current . account_id } :certificate/*" ,
260266 ]
261- }
267+ },
262268 ]
263269 })
264270
You can’t perform that action at this time.
0 commit comments