fix(API): Extend list of configs influencing X-Nextcloud-Talk-Hash header

Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
Joas Schilling 2023-03-21 13:55:15 +01:00
parent 6d887a87a7
commit 70e25dc91c
No known key found for this signature in database
GPG key ID: 74434EFE0D2E2205
2 changed files with 60 additions and 49 deletions

View file

@ -51,47 +51,48 @@
When available the dedicated UI or OCC command option should be used to configure the setting rather than directly manipulating the database.
Option legend:
Legend:
* `Hash` - Whether the changing the config changes the Talk version hash triggering clients to refresh capabilities
* πŸ–ŒοΈ - UI option in the admin settings available
* πŸ’» - Dedicated OCC command available
| Key | Internal type | Default | Option | Valid values |
|--------------------------------------|------------------------------------------------------------------|------------|--------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `allowed_groups` | string[] | `[]` | πŸ–ŒοΈ | List of group ids that are allowed to use Talk |
| `sip_bridge_groups` | string[] | `[]` | πŸ–ŒοΈ | List of group ids that are allowed to enable SIP dial-in in a conversation |
| `start_conversations` | string[] | `[]` | πŸ–ŒοΈ | List of group ids that are allowed to create conversations |
| `hosted-signaling-server-account` | array | `{}` | πŸ–ŒοΈ | Account information of the hosted signaling server |
| `stun_servers` | array[] | `[]` | πŸ–ŒπŸ’»οΈ | List of STUN servers, should be configured via the web interface or the OCC commands |
| `turn_servers` | array[] | `[]` | πŸ–ŒοΈπŸ’» | List of TURN servers, should be configured via the web interface or the OCC commands |
| `recording_servers` | array[] | `[]` | πŸ–ŒοΈ | List of recording servers, should be configured via the web interface |
| `signaling_servers` | array[] | `[]` | πŸ–ŒοΈπŸ’» | List of signaling servers, should be configured via the web interface or the OCC commands |
| `signaling_mode` | string<br>`internal` or `external` or `conversation_cluster` | `internal` | | `internal` when no HPB is configured, `external` when configured, `conversation_cluster` is an experimental flag that is deprecated |
| `sip_bridge_dialin_info` | string | | πŸ–ŒοΈ | Additional information added in the SIP dial-in invitation mail and sidebar |
| `sip_bridge_shared_secret` | string | | πŸ–ŒοΈ | Shared secret allowing the SIP bridge to authenticate on the Nextcloud server |
| `signaling_ticket_secret` | string | | | Secret used to secure the signaling tickets for guests (255 character random string) |
| `signaling_token_alg` | string<br>`ES256`, `ES384`, `RS256`, `RS384`, `RS512` or `EdDSA` | `ES256` | | Algorithm for the signaling tickets |
| `signaling_token_privkey_*` | string | * | | Private key for the signaling ticket creation by the server |
| `signaling_token_pubkey_*` | string | * | | Public key for the signaling ticket creation by the server |
| `hosted-signaling-server-nonce` | string | | | Temporary nonce while configuring the hosted signaling server |
| `hosted-signaling-server-account-id` | string | | | Account identifier of the hosted signaling server |
| `matterbridge_binary` | string | | | Path to the matterbridge binary file |
| `bridge_bot_password` | string | | | Automatically generated password of the matterbridge bot user profile |
| `default_attachment_folder` | string | `/Talk` | | Specify default attachment folder location |
| `start_calls` | int | `0` | πŸ–ŒοΈ | Who can start a call, see [constants list](constants.md#start-call) |
| `max-gif-size` | int | `3145728` | | Maximum file size for clients to render gifs previews with animation |
| `session-ping-limit` | int | `200` | | Number of sessions the HPB can ping in a single request |
| `token_entropy` | int | `8` | | Length of conversation tokens, can be increased to make tokens harder to guess but reduces readability and dial-in comfort |
| `default_group_notification` | int | `2` | πŸ–ŒοΈ | Default notification level for group conversations [constants list](constants.md#participant-notification-levels) |
| `default_permissions` | int | `246` | | Default permissions for non-moderators (see [constants list](constants.md#attendee-permissions) for bit flags) |
| `grid_videos_limit` | int | `19` | | Maximum number of videos to show (additional to the own video) |
| `grid_videos_limit_enforced` | string<br>`yes` or `no` | `no` | | Whether the number of grid videos should be enforced |
| `changelog` | string<br>`yes` or `no` | `yes` | | Whether the changelog conversation is updated with new features on major releases |
| `has_reference_id` | string<br>`yes` or `no` | `no` | | Indicator whether the clients can use the reference value to identify their message, will be automatically set to `yes` when the repair steps are executed |
| `hide_signaling_warning` | string<br>`yes` or `no` | `no` | πŸ–ŒοΈ | Flag that allows to suppress the warning that an HPB should be configured |
| `breakout_rooms` | string<br>`yes` or `no` | `yes` | | Whether or not breakout rooms are allowed (Will only prevent creating new breakout rooms. Existing conversations are not modified.) |
| `call_recording` | string<br>`yes` or `no` | `yes` | | Enable call recording |
| `federation_enabled` | string<br>`yes` or `no` | `no` | | πŸ—οΈ *Work in progress:* Whether or not federation with this instance is allowed |
| `conversations_files` | string<br>`1` or `0` | `1` | πŸ–ŒοΈ | Whether the files app integration is enabled allowing to start conversations in the right sidebar |
| `conversations_files_public_shares` | string<br>`1` or `0` | `1` | πŸ–ŒοΈ | Whether the public share integration is enabled allowing to start conversations in the right sidebar on the public share page (Requires `conversations_files` also to be enabled) |
| `enable_matterbridge` | string<br>`1` or `0` | `0` | πŸ–ŒοΈ | Whether the matterbridge integration is enabled and can be configured |
| Key | Internal type | Default | Hash | Option | Valid values |
|--------------------------------------|------------------------------------------------------------------|------------|------|--------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `allowed_groups` | string[] | `[]` | Yes | πŸ–ŒοΈ | List of group ids that are allowed to use Talk |
| `sip_bridge_groups` | string[] | `[]` | Yes | πŸ–ŒοΈ | List of group ids that are allowed to enable SIP dial-in in a conversation |
| `start_conversations` | string[] | `[]` | Yes | πŸ–ŒοΈ | List of group ids that are allowed to create conversations |
| `hosted-signaling-server-account` | array | `{}` | No | πŸ–ŒοΈ | Account information of the hosted signaling server |
| `stun_servers` | array[] | `[]` | Yes | πŸ–ŒπŸ’»οΈ | List of STUN servers, should be configured via the web interface or the OCC commands |
| `turn_servers` | array[] | `[]` | Yes | πŸ–ŒοΈπŸ’» | List of TURN servers, should be configured via the web interface or the OCC commands |
| `recording_servers` | array[] | `[]` | Yes | πŸ–ŒοΈ | List of recording servers, should be configured via the web interface |
| `signaling_servers` | array[] | `[]` | Yes | πŸ–ŒοΈπŸ’» | List of signaling servers, should be configured via the web interface or the OCC commands |
| `signaling_mode` | string<br>`internal` or `external` or `conversation_cluster` | `internal` | Yes | | `internal` when no HPB is configured, `external` when configured, `conversation_cluster` is an experimental flag that is deprecated |
| `sip_bridge_dialin_info` | string | | Yes | πŸ–ŒοΈ | Additional information added in the SIP dial-in invitation mail and sidebar |
| `sip_bridge_shared_secret` | string | | Yes | πŸ–ŒοΈ | Shared secret allowing the SIP bridge to authenticate on the Nextcloud server |
| `signaling_ticket_secret` | string | | Yes | | Secret used to secure the signaling tickets for guests (255 character random string) |
| `signaling_token_alg` | string<br>`ES256`, `ES384`, `RS256`, `RS384`, `RS512` or `EdDSA` | `ES256` | Yes | | Algorithm for the signaling tickets |
| `signaling_token_privkey_*` | string | * | Yes | | Private key for the signaling ticket creation by the server |
| `signaling_token_pubkey_*` | string | * | Yes | | Public key for the signaling ticket creation by the server |
| `hosted-signaling-server-nonce` | string | | No | | Temporary nonce while configuring the hosted signaling server |
| `hosted-signaling-server-account-id` | string | | No | | Account identifier of the hosted signaling server |
| `matterbridge_binary` | string | | No | | Path to the matterbridge binary file |
| `bridge_bot_password` | string | | No | | Automatically generated password of the matterbridge bot user profile |
| `default_attachment_folder` | string | `/Talk` | No | | Specify default attachment folder location |
| `start_calls` | int | `0` | Yes | πŸ–ŒοΈ | Who can start a call, see [constants list](constants.md#start-call) |
| `max-gif-size` | int | `3145728` | No | | Maximum file size for clients to render gifs previews with animation |
| `session-ping-limit` | int | `200` | No | | Number of sessions the HPB can ping in a single request |
| `token_entropy` | int | `8` | No | | Length of conversation tokens, can be increased to make tokens harder to guess but reduces readability and dial-in comfort |
| `default_group_notification` | int | `2` | No | πŸ–ŒοΈ | Default notification level for group conversations [constants list](constants.md#participant-notification-levels) |
| `default_permissions` | int | `246` | Yes | | Default permissions for non-moderators (see [constants list](constants.md#attendee-permissions) for bit flags) |
| `grid_videos_limit` | int | `19` | No | | Maximum number of videos to show (additional to the own video) |
| `grid_videos_limit_enforced` | string<br>`yes` or `no` | `no` | No | | Whether the number of grid videos should be enforced |
| `changelog` | string<br>`yes` or `no` | `yes` | No | | Whether the changelog conversation is updated with new features on major releases |
| `has_reference_id` | string<br>`yes` or `no` | `no` | Yes | | Indicator whether the clients can use the reference value to identify their message, will be automatically set to `yes` when the repair steps are executed |
| `hide_signaling_warning` | string<br>`yes` or `no` | `no` | No | πŸ–ŒοΈ | Flag that allows to suppress the warning that an HPB should be configured |
| `breakout_rooms` | string<br>`yes` or `no` | `yes` | Yes | | Whether or not breakout rooms are allowed (Will only prevent creating new breakout rooms. Existing conversations are not modified.) |
| `call_recording` | string<br>`yes` or `no` | `yes` | Yes | | Enable call recording |
| `federation_enabled` | string<br>`yes` or `no` | `no` | Yes | | πŸ—οΈ *Work in progress:* Whether or not federation with this instance is allowed |
| `conversations_files` | string<br>`1` or `0` | `1` | No | πŸ–ŒοΈ | Whether the files app integration is enabled allowing to start conversations in the right sidebar |
| `conversations_files_public_shares` | string<br>`1` or `0` | `1` | No | πŸ–ŒοΈ | Whether the public share integration is enabled allowing to start conversations in the right sidebar on the public share page (Requires `conversations_files` also to be enabled) |
| `enable_matterbridge` | string<br>`1` or `0` | `0` | No | πŸ–ŒοΈ | Whether the Matterbridge integration is enabled and can be configured |

View file

@ -148,15 +148,25 @@ class RoomController extends AEnvironmentAwareController {
return [
'X-Nextcloud-Talk-Hash' => sha1(
$this->config->getSystemValueString('version') . '#' .
$this->config->getAppValue('spreed', 'installed_version', '') . '#' .
$this->config->getAppValue('spreed', 'stun_servers', '') . '#' .
$this->config->getAppValue('spreed', 'turn_servers', '') . '#' .
$this->config->getAppValue('spreed', 'signaling_servers', '') . '#' .
$this->config->getAppValue('spreed', 'signaling_mode', '') . '#' .
$this->config->getAppValue('spreed', 'allowed_groups', '') . '#' .
$this->config->getAppValue('spreed', 'start_calls', '') . '#' .
$this->config->getAppValue('spreed', 'start_conversations', '') . '#' .
$this->config->getAppValue('spreed', 'has_reference_id', '') . '#' .
$this->config->getAppValue('spreed', 'installed_version') . '#' .
$this->config->getAppValue('spreed', 'stun_servers') . '#' .
$this->config->getAppValue('spreed', 'turn_servers') . '#' .
$this->config->getAppValue('spreed', 'signaling_servers') . '#' .
$this->config->getAppValue('spreed', 'signaling_mode') . '#' .
$this->config->getAppValue('spreed', 'signaling_ticket_secret') . '#' .
$this->config->getAppValue('spreed', 'signaling_token_alg', 'ES256') . '#' .
$this->config->getAppValue('spreed', 'signaling_token_privkey_' . $this->config->getAppValue('spreed', 'signaling_token_alg', 'ES256')) . '#' .
$this->config->getAppValue('spreed', 'signaling_token_pubkey_' . $this->config->getAppValue('spreed', 'signaling_token_alg', 'ES256')) . '#' .
$this->config->getAppValue('spreed', 'call_recording') . '#' .
$this->config->getAppValue('spreed', 'recording_servers') . '#' .
$this->config->getAppValue('spreed', 'allowed_groups') . '#' .
$this->config->getAppValue('spreed', 'start_calls') . '#' .
$this->config->getAppValue('spreed', 'start_conversations') . '#' .
$this->config->getAppValue('spreed', 'default_permissions') . '#' .
$this->config->getAppValue('spreed', 'breakout_rooms') . '#' .
$this->config->getAppValue('spreed', 'federation_enabled') . '#' .
$this->config->getAppValue('spreed', 'enable_matterbridge') . '#' .
$this->config->getAppValue('spreed', 'has_reference_id') . '#' .
$this->config->getAppValue('spreed', 'sip_bridge_groups', '[]') . '#' .
$this->config->getAppValue('spreed', 'sip_bridge_dialin_info') . '#' .
$this->config->getAppValue('spreed', 'sip_bridge_shared_secret') . '#' .