Check ID:
Provider: AWS
Service:
Severity: MEDIUM
Categories:
Resource type:
apigateway_restapi_logging_enabledProvider: AWS
Service:
apigatewaySeverity: MEDIUM
Categories:
logging, forensics-readyResource type:
AwsApiGatewayStageWhat this check verifies
API Gateway REST API stages with stage logging enabled to emit execution or access logs to CloudWatchRisk
Without stage logging, API activity lacks visibility, hindering detection of abuse and incident response. Attackers can probe endpoints, exfiltrate data, or tamper integrations without traces, impacting confidentiality, integrity, and availability and blocking forensic investigation.Recommendation
Enable CloudWatch Logs for all API Gateway stages, usingERROR or INFO as appropriate. Include request IDs (e.g., $context.requestId). Enforce least privilege on logs, set retention and alerts for anomalies. Avoid sensitive data in logs and use defense in depth with tracing.
Remediation
- CLI
- Terraform
- Native IaC
- Dashboard steps
References
- https://docs.aws.amazon.com/apigateway/latest/developerguide/security-monitoring.html
- https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-logging.html
- https://www.trendmicro.com/trendaivisiononecloudriskmanagement/knowledge-base/aws/APIGateway/cloudwatch-logs.html
- https://docs.aws.amazon.com/apigateway/latest/developerguide/set-up-logging.html
- https://repost.aws/knowledge-center/api-gateway-cloudwatch-logs
- https://repost.aws/knowledge-center/api-gateway-missing-cloudwatch-logs
- https://docs.aws.amazon.com/apigateway/latest/developerguide/view-cloudwatch-log-events-in-cloudwatch-console.html
Where this check fires
This check runs on every scheduled scan against your AWS account. Findings appear at Cloud Security → Findings filterable byCheck ID = apigateway_restapi_logging_enabled. To re-evaluate after a fix, hit Run now on the account’s schedule under Cloud Security → Schedules — the next scan re-checks this control and marks the finding fixed or keeps it persistent.
← Back to AWS checks