IGNITE-22844 control.sh --consistency repair permissions fixes #11456
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Intro:
Currently 'Read Repair' task performed for the chosen partitions by control.sh requires CACHE_READ and CACHE PUT permissions in addition to ADMIN_OPS. Thus, to perform the comand
control.sh --consistency repair
the one needs all 3 permissions.There is no point to have additional CACHE_READ and CACHE_PUT permissions to perform the operation, as they are useless for the task itself, and introduces security risk, by allowing the user to manipulate the cache in parallel.
The solution would be to substitute user's security context with the context of the cluster node that performs the command. The former is used for the ADMIN_OPS permission check and the latter is used for cache. This will ease the requirement for the users to perform
control.sh --consistency repair
without introducing any additional security risk.What have I changed:
control.sh --consistency repair
command with no authorization error relates to CACHE_READ and CACHE_PUTThank you for submitting the pull request to the Apache Ignite.
In order to streamline the review of the contribution
we ask you to ensure the following steps have been taken:
The Contribution Checklist
The description explains WHAT and WHY was made instead of HOW.
The following pattern must be used:
IGNITE-XXXX Change summary
whereXXXX
- number of JIRA issue.(see the Maintainers list)
the
green visa
attached to the JIRA ticket (see TC.Bot: Check PR)Notes
If you need any help, please email [email protected] or ask anу advice on http://asf.slack.com #ignite channel.