Skip to content

webacl.resource.hasRights: if we have acl:Write permission, we should also have acl:Append permission #1404

Description

@srosset81

If a user is given acl:Write permissions on a resource, and we then call webacl.resource.hasRights, it will return that this user has no acl:Append permission.

This is not a bug since this is acknowledged in tests:

expect(resourceRights).toMatchObject({
read: true,
write: true,
append: false,
control: true
});

Note that the Fuseki WAC extension considers that a user with acl:Write permission has also full permission to append.

So my proposal would be to refactor the webacl.resource.hasRights so that, if a user has acl:Write permission, it will also return append: true. This way the webacl.resource.hasRights action reflects what is done by the Fuseki WAC extension.

What do you think @nikoPLP ? Could it have bad side effect on other parts of the code ? And as a side question:

  • Should we also consider that someone with acl:Write permission also has acl:Read permission ?
  • What about acl:Control ? Does the Fuseki extension consider this also grants all other permissions ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions