# Configuring Asterisk to Use Asterphone with PJSIP

### Global settings

Settings - Asterisk SIP settings

<table data-full-width="false"><thead><tr><th width="367">SIP settings (chan_pjsip)</th><th></th><th data-hidden></th><th data-hidden></th></tr></thead><tbody><tr><td>Misc PJSip Settings</td><td>taskprocessor overload trigger = pjsip_only</td><td></td><td></td></tr><tr><td>TLS/SSL/SRTP Settings</td><td>certificate manager = example.simple.test<br>ssl method = tlsv1_2</td><td></td><td></td></tr><tr><td>wss</td><td>wss - 0.0.0.0 - All = No<br>wss - 10.0.0.133 - ens18 = Yes</td><td></td><td></td></tr></tbody></table>

Settings - Advanced Settings

| Asterisk Builtin mini-HTTP server |
| --------------------------------- |
| Force WebSocket Mode = pjsip      |

### Add extension

Connectivity - Add Extension - Add New \[chan\_pjsip] Extension

| General       |                                                                                                                                                                                                                                                                                                          |
| ------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Add Extension | <p><strong>extension = 100</strong> (internal phone number)</p><p><strong>display name = 100</strong> (must match the extension - the number that will be displayed when the call is made)</p><p><strong>secret</strong> - password, filled in automatically, required field, you can enter your own</p> |

<table><thead><tr><th width="374">Advanced</th><th></th></tr></thead><tbody><tr><td>Add Extension</td><td><p><strong>enable avpf = true</strong><br><strong>i</strong>f you leave it set to “no,” the connection is established successfully, and the call reaches the recipient, but is immediately disconnected<br><br><strong>enable ICESupport = true</strong></p><p>if you leave it set to “no,” the connection is established successfully, and the call reaches the recipient, but is immediately disconnected<br><br><strong>enable rtcpMux = true</strong></p><p>if you leave it set to “no,” the connection is established successfully, and the call reaches the recipient, but is immediately disconnected<br><br><strong>media encryption = dtls-srtp</strong> <strong>(not recommended)</strong><br>сonfiguring media stream encryption<br><br><strong>enable dtls = yes</strong><br>use encryption<br><br><strong>use certificate &#x3C;example>.com (select current)</strong><br>select a certificate</p></td></tr></tbody></table>

| Tab Advanced → Section Edit Extension |                       |
| ------------------------------------- | --------------------- |
| Transport                             | All - WSS Primary     |
| Enable AVPF                           | Yes                   |
| Force AVP                             | Yes                   |
| Enable ICE Support                    | Yes                   |
| Enable rtcp Mux                       | Yes                   |
| Enable Encryption                     | Yes (SRTP only)       |
| Section DTLS                          |                       |
| Enable DTLS                           | Yes (there should be) |
| Use Certificate                       | \<example>.com        |
