Catch Me If You Can: How LocalStack’s Policy Stream Identifies Least Privilege IAM Policies
summary
LocalStack’s IAM Policy Stream records every AWS API call your app makes locally and generates policies per API call that map back to the principal or resource, producing concrete JSON policy suggestions (S3: GetObject/PutObject, Lambda: ListFunctions/GetFunction, SQS create/send/receive) you can drop into Terraform. It runs inside the LocalStack Docker image (LocalStack supports 100+ APIs), can run permissive by default or emulate production with force IAM enforcement via FORCE_IAM=1, and surfaces missing permissions during a serverless image-resizer deploy so you can right-size and test least-privilege rules before cloud rollout.
AI-written summary · about
