Skip to content

fix: Correct IAM policies for pipes that use MSK as a source. #165

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

robert-matusewicz
Copy link

@robert-matusewicz robert-matusewicz commented May 26, 2025

Description

This addresses issue #164
The current implementation of the IAM policy for pipes that use MSK as a source is incorrect. It restricts the following actions:

  • ec2:DescribeNetworkInterfaces
  • ec2:DescribeSecurityGroups
  • ec2:DescribeSubnets
  • ec2:DescribeVpcs
  • ec2:CreateNetworkInterface
  • ec2:DeleteNetworkInterface

to the MSK cluster ARN, but all of them require a wildcard resource ("*").

I am aiming to fix this issue with the change in this PR.

In addition, I added an example of a pipe with MSK as a source and a sqs as a target.

Motivation and Context

The correct IAM permissions are not valid for a pipe with MSK source.

Breaking Changes

No

How Has This Been Tested?

  • I have updated at least one of the examples/* to demonstrate and validate my change(s)
  • I have tested and validated these changes using one or more of the provided examples/* projects
  • I have executed pre-commit run -a on my pull request

The ec2:* actions accept only "*" as a resource.

Added example of pipes with MSK as a source and sqs as a target.
@robert-matusewicz robert-matusewicz changed the title Fix IAM policies for pipes that use MSK as a source. fix: correct IAM policies for pipes that use MSK as a source. May 26, 2025
@robert-matusewicz robert-matusewicz changed the title fix: correct IAM policies for pipes that use MSK as a source. fix: Correct IAM policies for pipes that use MSK as a source. May 26, 2025
@robert-matusewicz
Copy link
Author

@svenlito any chance you could review this any time soon, please?

@robert-matusewicz
Copy link
Author

@antonbabenko maybe you could help review this PR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant