-
Couldn't load subscription status.
- Fork 337
[Resource Permissions] Introduces Centralized Resource Access Control Framework #5281
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
Conversation
…strate usage of Resource Access Control feature (#5187) Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
cf377b6 to
88ad450
Compare
Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
...plugin/src/integrationTest/java/org/opensearch/sample/AbstractSampleResourcePluginTests.java
Outdated
Show resolved
Hide resolved
...src/main/java/org/opensearch/sample/resource/actions/rest/share/ShareResourceRestAction.java
Outdated
Show resolved
Hide resolved
...lugin/src/main/java/org/opensearch/sample/resource/client/ResourceSharingClientAccessor.java
Outdated
Show resolved
Hide resolved
src/main/java/org/opensearch/security/resources/ResourceAccessControlClient.java
Show resolved
Hide resolved
Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
22e0d96 to
6ccfcdf
Compare
Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
6173cc7 to
a4615fa
Compare
...c/main/java/org/opensearch/sample/resource/actions/transport/GetResourceTransportAction.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
src/main/java/org/opensearch/security/resources/ResourcePluginInfo.java
Outdated
Show resolved
Hide resolved
spi/src/main/java/org/opensearch/security/spi/resources/FeatureConfigConstants.java
Outdated
Show resolved
Hide resolved
...c/main/java/org/opensearch/sample/resource/actions/transport/GetResourceTransportAction.java
Show resolved
Hide resolved
src/main/java/org/opensearch/security/OpenSearchSecurityPlugin.java
Outdated
Show resolved
Hide resolved
…dds @nonnull to arguments Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
…rce-sharing document related method to ResourceSharing class Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the persistence @DarshitChanpura. Approving this PR with some of the comments remaining above, particularly around setting up extendedPlugins within the integrationTest framework.
I think this change is sufficiently isolated behind the experimental feature flag where the new classes initialized in OpenSearchSecurityPlugin are not used/instantiated unless the feature flag is enabled.
I really wanted to laud the introduction of this new extensibility model which I can see extended further in the future for other use-cases for plugins integrating with security and really paves the path forward for getting rid of the awkward existing plugin use-cases reading the user from the threadcontext and storing a copy in their own system indices either for this sharing use-case or for the job scheduler use case where they inject the roles back in at job runtime.
I also wanted to leave this quote: opensearch-project/OpenSearch#4459 (comment)
Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
src/main/java/org/opensearch/security/resources/ResourceSharingIndexHandler.java
Show resolved
Hide resolved
src/main/java/org/opensearch/security/resources/ResourceSharingIndexHandler.java
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Marking as approved again with additional comments.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, Darshit Chanpura
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks
Description
Introduces Centralized Resource Access Control framework by declaring a new SPI for plugins to extend ResourceSharingExtension and use ResourceSharingClient to utilize the resource access control APIs. Design outlined in the proposal below.
Issues Resolved
Testing
Check List
- [ ] New Roles/Permissions have a corresponding security dashboards plugin PR- [ ] API changes companion pull request createdBy submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.