|
|
|
|
|
by podviaznikov
2791 days ago
|
|
Hi, edsu seems very interesting. I've looked through examples and read docs.
Question:
is it possible to make an app and allow user to set permissions.
E.g. lets say I have writing app. I want initially to create writings as `private` and then promote them to `public`. I don't see if it's possible.
I see that scope is fixed for now in the name like that `prv.app.edsu-org.hello-world.storage`. So I assume `token` only works for `prv.app.edsu-org.hello-world.storage` but wouldn't work for `pub.app.edsu-org.hello-world.storage` or would it? |
|
If an app wanted to be able to switch something from public to private or back, it'd get a token with write permissions for two names, one with the prv.* prefix, and one with the pub.* prefix. And that's a good thing: it makes it clear to the user that the app is requesting the ability to make the things that they write public.
It's still just one grant request, it's just that there'd be two line items instead of one. Also, names are simple pointers to blocks of data, so, for instance, if both names happen to be pointing to the same written piece, there's no duplication of data.