How can I use attribute-based access control (ABAC) in pipelines? #5364
Replies: 1 comment 1 reply
-
If the same role is used to send to OpenSearch Service across different pipelines, I am not aware of a way to only allow the pipeline to send to a specific index. Maybe there is some path for Data Prepper to be configurable to block calls to any other index by dynamically applying a policy to the assume role call like you're suggestion, but using the same role as is for both the domain access policy and FGAC permissions will provide permissions the full permissions to the role (https://docs.aws.amazon.com/opensearch-service/latest/developerguide/ac.html, https://opensearch.org/docs/latest/security/access-control/permissions/#index-permissions). |
Beta Was this translation helpful? Give feedback.
-
Hello everyone,
Here is the scenario in my multi-tenant application on AWS OpenSearch Service:
To ensure tenant isolation, it is recommended to have one data prepper pipeline per tenant.
In the sink configuration, there is a field called sts_role_arn. This allows me to define a role that restricts access to only the tenant's index.
However, I have a problem: I can't create a separate role for each tenant because there is a limit on the number of roles (and we have thousands of tenants). Instead, the solution is to use attribute-based access control (ABAC), as mentioned in this article.
In my application, when retrieving data from the tenant index, I use temporary credentials (assume role) with ABAC.
Here’s how it works:
We created a single role with access to all indexes.
When I assume the role, I dynamically create a policy to restrict access to the specific tenant's index.
Role Definition:
Dynamic Policy Generation:
Now, I need similar behavior for creating a sink. I can use the sts_role_arn field, but I also need a way to define a complementary policy dynamically to guarantee tenant isolation.
I will need this on S3 as a source as well.
Beta Was this translation helpful? Give feedback.
All reactions