-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[aws-kinesis] Read permissions to stream doesn't include kinesis:DescribeStream #10783
Comments
@shivlaks Do you know why was the @Alexander-D-Jensen - As a workaround, you can use Custom Permissions to add this action. |
I have done so afterwards, via the following: However, I run into issues with Cloudformation, which tries to create the Firehose before the IAM policy is ready, and then it fails. In other words, despite adding the permissions explicitly, I am no closer to a successful deployment of the stack at that point. Finally, I've arrived at the following workaround:
I am not sure if this is within the scope of CDK to handle or not, though I suspect the better solution would be for CloudFormation to handle it (correctly). |
@Alexander-D-Jensen Thanks, we'll take a look. Do you mind sharing the entire code you use? Including where you define the firehose and the stream itself? |
Sure @iliapolo! This is stack A, the stack which had the issue:
This is stack B, which creates the Kinesis stream
And finally, we have the stack which coordinates the whole thing:
I hope this helps :) |
Hi @Alexander-D-Jensen - thanks for sharing the code. It was very helpful. So there are actually two separate issues here: First is that We will consider adding this action back to the policy. Second is that the This type of thing is exactly what an L2 for a I've created an issue for the L2 construct to make sure we consider this scenario when we start working on it. |
|
When granting an IAM role read permissions on a Kinesis stream, the resulting policy does not include the "kinesis:DescribeStream" permission, which is needed for at least Kinesis Firehose to read from it, perhaps other consumers as well.
Reproduction Steps
Results in the following output:
What did you expect to happen?
I expected the resulting IAM role and policy to actually be able to read from the supplied Kinesis stream when used by Kinesis Firehose. This would require the "kinesis:DescribeStream" permission to be given.
What actually happened?
Stack creation fails, because the "kinesis:DescribeStream" permission is lacking.
Cloudformation gives the following error:
Role arn:aws:iam::<account>:role/<role_name> is not authorized to perform: kinesis:DescribeStream on resource arn:aws:kinesis:eu-west-1:<account>:stream/<stream_name>. (Service: Firehose, Status Code: 400, Request ID: <request_id>, Extended Request ID: <extended_request_id>
Environment
Other
This is 🐛 Bug Report
The text was updated successfully, but these errors were encountered: