There is 1 update.
 
 
Rights API / cid:jira-generated-image-avatar-0523a900-667c-42e0-9a17-e7c999fd6cee RIGHTSAPI-38 Open

Add APIs to help extract rules from a set of rules based on unique subject and subject type

 
View issue   ยท   Add comment
 

1 update

 
cid:jira-generated-image-avatar-883bb955-a968-4530-a5d2-beda753e146c Changes by Mohamed Boussaa on 26/Jul/24 11:02
 
Description: This task is about implementing new APIs to help :
* Extract rules whose subject is a user or a group, the returned rules

     * {@link #normalizeRulesBySubject
are normalized ( List<ReadableSecurityRule> see RIGHTSAPI-20 ) } method.

* Extract rules from Organize a set of rules based subject type (user/group) and . Basically for each subject found on the original list of rules we will have a Map entry with the subject DocumentReference as key reference and a Pair of rules ( rule for allowed rights, rule for denied rights state (Allow/Deny ) as value.

The following APIs will be added :

*
Map List < DocumentReference, Pair< ReadableSecurityRule , ReadableSecurityRule > > getRulesByUniqueUser getUserRulesNormalized (List<ReadableSecurityRule> rules) : Extract rules by unique whose subject is a user from a set of rules. Returned rules are normalized.
*
Map List < DocumentReference, Pair< ReadableSecurityRule , ReadableSecurityRule > > getRulesByUniqueUser getGroupRulesNormalized (
        List<ReadableSecurityRule> rules) : Extract rules by unique user whose subject is a group from a set of rules. Returned rules are normalized.
* Map<DocumentReference, Pair<ReadableSecurityRule, ReadableSecurityRule>>
getRulesByUniqueGroup organizeRulesBySubjectAndState (
        List<ReadableSecurityRule> rules) :
Extract rules by unique group from Organize a set of rules based on subject reference and rule state (Allow/Deny) .