|
| 1 | +--- |
| 2 | +title: WSS Transport |
| 3 | +sidebar_position: 7 |
| 4 | +--- |
| 5 | + |
| 6 | +# WSS Transport {#wss-transport} |
| 7 | + |
| 8 | +NethVoice on NethServer 8 supports WebSocket Secure (WSS) transport for extensions. Each NethVoice instance exposes a specific WSS port dedicated to WebSocket connections. |
| 9 | + |
| 10 | +:::warning Network Constraint |
| 11 | +This configuration relies on direct connectivity and **does not function behind NAT**. Ensure NethVoice has direct network visibility to the client endpoints. |
| 12 | +::: |
| 13 | + |
| 14 | +## Service Configuration {#service-configuration} |
| 15 | + |
| 16 | +The WSS port assigned to the specific NethVoice instance is defined dynamically. |
| 17 | + |
| 18 | +* **Variable:** `ASTERISK_WSS_PORT` |
| 19 | +* **Location:** Inside the module environment variables. |
| 20 | + |
| 21 | +Clients connecting to NethVoice via WebRTC or other WebSocket-based protocols must target this specific port. |
| 22 | + |
| 23 | +## Extension Setup {#extension-setup} |
| 24 | + |
| 25 | +To utilize WSS, the extension must be configured within the **Advanced Interface** (FreePBX). |
| 26 | + |
| 27 | + |
| 28 | +### Prerequisites {#prerequisites} |
| 29 | + |
| 30 | +1. Create a new **Custom Extension** or edit an existing one. |
| 31 | +2. Access the **Advanced Interface**. |
| 32 | + |
| 33 | +### Transport Settings {#transport-settings} |
| 34 | + |
| 35 | +Modify the extension `Advanced` settings with the following parameters to enable secure WebSocket transport: |
| 36 | + |
| 37 | +1. **Outbound Proxy:** Remove proxy configurations for this specific extension. |
| 38 | +2. **Transport:** Set to `0.0.0.0-wss`. |
| 39 | +3. **Enable AVPF:** Set to `Yes`. |
| 40 | +4. **Enable ICE Support:** Set to `Yes`. |
| 41 | +5. **Enable rtcp Mux:** Set to `Yes`. |
| 42 | +6. **Media Encryption:** Set to `DTLS`. |
| 43 | +7. **Enable WebRTC Defaults:** Enable this setting to apply standard WebRTC optimizations. |
| 44 | + |
| 45 | +## Client Configuration {#client-configuration} |
| 46 | + |
| 47 | +Configure your client with the following settings. Ensure your client device has network access to the NethVoice instance. |
| 48 | + |
| 49 | +| Parameter | Value / Instruction | |
| 50 | +| :--- | :--- | |
| 51 | +| **SIP Server / Domain** | The FQDN of your NethVoice instance. | |
| 52 | +| **SIP Proxy** | (Leave empty). | |
| 53 | +| **Transport Protocol** | **WSS** (Secure WebSocket). | |
| 54 | +| **Port** | The value of `ASTERISK_WSS_PORT` (check your module environment variables). | |
| 55 | +| **Path** | `/ws` (Default Asterisk WebSocket path). | |
| 56 | +| **Username / Extension** | The extension number (e.g., `1001`). | |
| 57 | +| **Password / Secret** | The extension secret defined in FreePBX. | |
| 58 | +| **Media Encryption** | **DTLS** (Mandatory for WebRTC/WSS). | |
| 59 | +| **AVPF** | Enabled / Yes. | |
| 60 | +| **ICE Support** | Enabled / Yes. | |
| 61 | + |
| 62 | +:::warning SSL Certificate Trust |
| 63 | +WSS requires a valid SSL certificate. If you are using a self-signed certificate, the client device (or browser) **must explicitly trust the certificate Authority (CA)** before the connection can be established. |
| 64 | +::: |
| 65 | + |
0 commit comments