Re: [w3c/manifest] User-approved permissions (#967)

It seems to one that an `Install Time Permissions Prompt` is indeed the way to go for web applications.

In the case of more complex permissions, the browser prompt might also ask for user's input in order to override default permissions values and persist them for future sessions.

Also, the web application should be able to reprompt the user in the case there is a need for changing the permissions while using the application, a bit like a form of "application settings" that could be modified by the user at any time.

In Script Tag extension proposal ([#6541](https://github.com/whatwg/html/issues/6541)), one suggested an install prompt mechanism, as well as a "permissions" key with an array of permissions objects, allowing arbitrary complexity for the permissions, such as:

```json
{
 "permissions": [
  {
   "deno": {
    "allow-write": "path/to/mydocumentfolder",
    "allow-net": "https://application.com"
   }
  }
 ]
}
```
One could also imagine a description property into the permissions objects so that the user is better informed about what they are in the prompt.

For example:

```json
{
 "permissions": [
  {
   "deno": [
    {
     "name": "allow-write",
     "description": "Allow the application to write into the local folder",
     "value": "path/to/mydocumentfolder"
    },
    {
     "name": "allow-net",
     "description": "Allow network requests to the following domain(s)",
     "value": ["https://application.com"]
    }
   ]
  }
 ]
}
```

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/manifest/issues/967#issuecomment-809729571

Received on Monday, 29 March 2021 21:34:13 UTC