docs: sandbox media-src for audio-capable plugins (radio)
This commit is contained in:
parent
dd9315c539
commit
40ad555b36
1 changed files with 6 additions and 1 deletions
|
|
@ -82,10 +82,15 @@ touch the app.
|
|||
|
||||
```
|
||||
location = /app/plugin-sandbox.html {
|
||||
add_header Content-Security-Policy "default-src 'none'; script-src 'unsafe-inline' 'unsafe-eval'; style-src 'unsafe-inline'; img-src data:; connect-src 'none'; frame-ancestors 'self'" always;
|
||||
add_header Content-Security-Policy "default-src 'none'; script-src 'unsafe-inline' 'unsafe-eval'; style-src 'unsafe-inline'; img-src data:; media-src https:; connect-src 'none'; frame-ancestors 'self'" always;
|
||||
}
|
||||
```
|
||||
|
||||
`media-src https:` lets a sandboxed plugin play an audio/video stream in its own
|
||||
iframe (e.g. the `orbit-radio` footer player). Playback stays contained — the
|
||||
iframe still can't `fetch`, read the response, or reach the app. Drop it if no
|
||||
deployment plugin needs media.
|
||||
|
||||
Applied live in `csp-app.conf` / `chat-headers.conf` (added `'self'` to `frame-src`)
|
||||
and a `location = /app/plugin-sandbox.html` block in `tchatou-app-backend.conf`.
|
||||
Note: nginx *reload* cannot rekey a shared-memory zone, so activating this needed a
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue