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

Use N3-Patch for WAC permissions #1234

Open
srosset81 opened this issue Feb 22, 2024 · 0 comments
Open

Use N3-Patch for WAC permissions #1234

srosset81 opened this issue Feb 22, 2024 · 0 comments
Labels
Milestone

Comments

@srosset81
Copy link
Contributor

srosset81 commented Feb 22, 2024

Currently WAC permissions use a special format to update WAC permissions through PATCH, as can be seen here:

https://github.com/assemblee-virtuelle/semapps/blob/next/src/frontend/packages/auth-provider/src/authProvider.js#L296-L310

If we used N3-patch like we do for containers and resources, it would uniformize our API and it would also allow to remove permissions without risks (right now we first GET the WAC permissions, filter out the permissions we don't want anymore, and then do a PUT, but if the resource is modified between the GET and the PUT, data may be lost).

Of course we could also support Sparql-Patch if we keep this format for other resources...

Even if nothing in the WAC spec prevent someone with a acl:Control right to write whatever they want in a WAC permission, we should probably check that only WAC-related predicates are added or removed. The @type and acl:accessTo triples (added automatically on creation) should not be modified.

@srosset81 srosset81 added the acl label Feb 22, 2024
@srosset81 srosset81 changed the title Use Sparql-Patch for WAC permissions Use Sparql-Patch (or N3 Patch) for WAC permissions May 16, 2024
@srosset81 srosset81 changed the title Use Sparql-Patch (or N3 Patch) for WAC permissions Use N3-Patch for WAC permissions May 30, 2024
@srosset81 srosset81 added this to the Version 2.0 milestone Nov 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant