Filter out space and organization names based on permissions #3962
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.
When a user has access to a shared service instance (i.e. read permissions on any of the shared spaces), the guids of all shared spaces are visible, but only those space and organization names the user is allowed to read based on the given roles.
Example
DEVELOPER who is space developer in SPACE_1, SPACE_2 and SPACE_3 shared SERVICE_INSTANCE from SPACE_1 to SPACE_2 and SPACE_3. For each space there is a dedicated space auditor (AUDITOR_1, AUDITOR_2 and AUDITOR_3).
Original behavior (before PR #3931):
SPACE_2.guid
+name
andSPACE_3.guid
+name
SPACE_2.name
andSPACE_3.name
should not be readableChanged behavior (with PR #3931):
SPACE_2.guid
+name
andSPACE_3.guid
+name
SPACE_2.name
andSPACE_3.name
should not be readableSPACE_2.guid
+name
andSPACE_3.guid
+name
SPACE_3.name
should not be readableSPACE_2.guid
+name
andSPACE_3.guid
+name
SPACE_2.name
should not be readableNew behavior (this change):
SPACE_2.guid
andSPACE_3.guid
SPACE_2.guid
+name
andSPACE_3.guid
SPACE_2.guid
andSPACE_3.guid
+name
I have reviewed the contributing guide
I have viewed, signed, and submitted the Contributor License Agreement
I have made this pull request to the
main
branchI have run all the unit tests using
bundle exec rake
I have run CF Acceptance Tests