IAM policy example: read a DynamoDB stream, with a least privilege rewrite
Facts read 16 Nov 2026. Page reviewed 16 Nov 2026.
Allows a consumer to read change records from the stream of one table: describe the stream, get a shard iterator and fetch records. The original allows dynamodb:* on the streams of every table. The rewrite names the Orders stream and three actions, plus ListStreams.
Open the workbench ยท All examples
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "Streams",
"Effect": "Allow",
"Action": "dynamodb:*",
"Resource": "arn:aws:dynamodb:us-east-1:111122223333:table/*/stream/*"
}
]
}
What it allows
- Allows every DynamoDB action on streams of all tables in one Region.
What it allows
Allow 85 actions (dynamodb:*) on arn:aws:dynamodb:us-east-1:111122223333:table/*/stream/*.
Action or pattern Actions Access levels dynamodb:*85 List 7, Read 31, Write 42, Permissions management 3, Tagging 2
Checks
No flags from the six checks.
The action dynamodb:* covers 85 actions and every table's stream.
Least privilege rewrite
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "ReadOrdersStream",
"Effect": "Allow",
"Action": [
"dynamodb:DescribeStream",
"dynamodb:GetShardIterator",
"dynamodb:GetRecords"
],
"Resource": "arn:aws:dynamodb:us-east-1:111122223333:table/Orders/stream/*"
},
{
"Sid": "ListStreams",
"Effect": "Allow",
"Action": "dynamodb:ListStreams",
"Resource": "*"
}
]
}
The rewrite lists the three stream-reading actions on the Orders stream and the list call that has no resource-level support.
What it allows
Allow 3 actions (dynamodb:DescribeStream, dynamodb:GetShardIterator, dynamodb:GetRecords) on arn:aws:dynamodb:us-east-1:111122223333:table/Orders/stream/*.
Action or pattern Actions Access levels dynamodb:DescribeStream1 Read 1 dynamodb:GetShardIterator1 Read 1 dynamodb:GetRecords1 Read 1 Allow 1 action (dynamodb:ListStreams) on every resource.
Action or pattern Actions Access levels dynamodb:ListStreams1 Read 1
Checks
No flags from the six checks.
Related pages
Sources
- Amazon DynamoDB Developer Guide: identity-based policies, read 16 Nov 2026
- AWS Service Authorization Reference, programmatic access (fetched 16 Nov 2026), read 16 Nov 2026
Last reviewed 16 Nov 2026.