Skip to content
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

[DRAFT] Add a base setup for resource access evaluation and adds a sample plugin #10

Draft
wants to merge 42 commits into
base: main
Choose a base branch
from
Draft
Changes from 1 commit
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
deb9c43
Explicitly create index before ingesting document in ComplianceAuditl…
cwperks Nov 20, 2024
49bc80f
Update Gradle to 8.11 (#4920)
reta Nov 20, 2024
9dfd5a0
Update Gradle to 8.11.1 (#4924)
reta Nov 20, 2024
831dca3
Add a base setup for resource access evaluation
DarshitChanpura Aug 30, 2024
1c65eff
Adds handler and other access management components for resource sharing
DarshitChanpura Sep 6, 2024
118cb07
Adds sample resource plugin
DarshitChanpura Sep 6, 2024
c41b67d
Removes node_modules entry from gitingore
DarshitChanpura Sep 6, 2024
45d4fa5
Handles changes related to scope
DarshitChanpura Oct 4, 2024
ae2464d
Updates sample plugin to implement a custom scope
DarshitChanpura Oct 4, 2024
aea2253
Fixes Checkstyle and spotless issues
DarshitChanpura Oct 4, 2024
1e17dc0
Fixes initialization error
DarshitChanpura Oct 4, 2024
84746e8
Renames sample resource plugin and adds a logger statement
DarshitChanpura Oct 4, 2024
83e4da0
Changes package name for sample plugin
DarshitChanpura Oct 4, 2024
4b9b9b1
Re-organizes and renames sample plugin files
DarshitChanpura Oct 4, 2024
81216f1
Updates method references to conform to core
DarshitChanpura Oct 4, 2024
1e33dad
Fixes compile errors
DarshitChanpura Oct 4, 2024
a671cc1
Fixes some names and method implementations
DarshitChanpura Oct 14, 2024
47b73da
Adds few concrete method implementations in security plugin
DarshitChanpura Oct 14, 2024
8942a80
Adds capability to introduce index listeners for all resource plugins
DarshitChanpura Oct 15, 2024
2b06603
Removes sampleplugin to be added in a separate PR
DarshitChanpura Nov 11, 2024
6f42bf1
Updates settings.gradle
DarshitChanpura Nov 11, 2024
45b002e
Fixes imports
DarshitChanpura Nov 20, 2024
a30be57
Adds concrete implementations of remainder methods
DarshitChanpura Nov 27, 2024
58003f6
Fixes spotless errors
DarshitChanpura Nov 27, 2024
078a976
Fixes log statement
DarshitChanpura Nov 27, 2024
8e44cf3
Renames ResourceManagement repository and add keyword to search query…
DarshitChanpura Dec 4, 2024
16a0ba6
Fixes delete method
DarshitChanpura Dec 4, 2024
ac53c8f
Fixes updateByQuery painless script
DarshitChanpura Dec 5, 2024
9e6ae85
Updates revoke handler to use painless script
DarshitChanpura Dec 5, 2024
0fe9779
Convert sets to lists
DarshitChanpura Dec 5, 2024
6d7f4c0
Explicitly casts painless entries to set to avoid duplicates
DarshitChanpura Dec 6, 2024
9d4ca1e
Fixes revoke access script
DarshitChanpura Dec 6, 2024
b4b22d6
Fixes revoke script to handle duplicates
DarshitChanpura Dec 6, 2024
e87bb80
Updates logger statement
DarshitChanpura Dec 7, 2024
5ad813b
Adds validation for resource ownership when granting and revoking access
DarshitChanpura Dec 7, 2024
c08a992
Adds super-admin bypass
DarshitChanpura Dec 10, 2024
8e3d41c
Updates method names and adds missing java doc
DarshitChanpura Dec 11, 2024
cabbcd6
Updates methods to return actual resources instead of resource ids
DarshitChanpura Dec 12, 2024
dc964ac
Stash context to fetch resources from a system index
DarshitChanpura Dec 13, 2024
cc973c6
Optimize call to fetch resources
DarshitChanpura Dec 13, 2024
3ce3d92
Updates javadoc
DarshitChanpura Dec 13, 2024
428e11e
Adds input validation
DarshitChanpura Dec 13, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Updates javadoc
Signed-off-by: Darshit Chanpura <[email protected]>
  • Loading branch information
DarshitChanpura committed Dec 13, 2024

Verified

This commit was signed with the committer’s verified signature.
DarshitChanpura Darshit Chanpura
commit 3ce3d92735a927b78e641b155a1c6104a61e781b
Original file line number Diff line number Diff line change
@@ -304,6 +304,7 @@ public <T> Set<T> fetchAllDocuments(String pluginIndex, Class<T> clazz) {
* <li>"roles" - for role-based access</li>
* <li>"backend_roles" - for backend role-based access</li>
* </ul>
* @param clazz Class to deserialize each document from Response into
* @return Set<String> List of resource IDs that match the criteria. The list may be empty
* if no matches are found
*
@@ -376,6 +377,7 @@ public <T> Set<T> fetchDocumentsForAllScopes(String pluginIndex, Set<String> ent
* <li>"backend_roles" - for backend role-based access</li>
* </ul>
* @param scope The scope of the access. Should be implementation of {@link org.opensearch.accesscontrol.resources.ResourceAccessScope}
* @param clazz Class to deserialize each document from Response into
* @return Set<String> List of resource IDs that match the criteria. The list may be empty
* if no matches are found
*
@@ -484,6 +486,7 @@ public <T> Set<T> fetchDocumentsForAGivenScope(
* @param pluginIndex The source index to match against the source_idx field
* @param field The field name to search in. Must be a valid field in the index mapping
* @param value The value to match for the specified field. Performs exact term matching
* @param clazz Class to deserialize each document from Response into
* @return Set<String> List of resource IDs that match the criteria. Returns an empty list
* if no matches are found
*