In this tutorial, we will guide you through the process of securing your Vicidial server and ViciPhone with SSL certificates from LetsEncrypt. Ensuring a secure connection is crucial, especially when dealing with sensitive information in a call center environment. Follow these step-by-step instructions to implement secure communication using WebRTC.
Step 1: Install LetsEncrypt
Run the following command to install LetsEncrypt on your server:
zypper install certbot python3-certbot-apache
Step 2: Create SSL Certificate
Generate SSL certificates for your Vicidial server and ViciPhone using the following command:
certbot certonly --webroot -w /path/of/webroot -d demo.example.com
Step 3: Configure Apache for SSL
Edit the Vicibox vhost file to include the SSL certificate information:
nano /etc/apache2/vhost.d/1111-default-ssl.conf
Update the SSLCertificateFile and SSLCertificateKeyFile paths with your certificate details.
Step 4: Redirect HTTP to HTTPS
Edit the specified file to add a redirect from HTTP to HTTPS:
nano /etc/apache2/vhost.d/1111.default.conf
Add the following line after DocumentRoot:
Redirect permanent / https://yourserverip/
Save the file and restart Apache:
systemctl restart apache2
Step 5: Install SSL Certificate in Asterisk
Update the Asterisk configuration file with SSL certificate information:
cd /etc/asterisk/
nano http.conf
Add the following details:
[general] enabled=yes bindaddr=0.0.0.0 bindport=8088 enablestatic=yes tlsenable=yes tlsbindaddr=0.0.0.0:8089 tlscertfile=/etc/letsencrypt/live/domain_name/cert.pem tlsprivatekey=/etc/letsencrypt/live/domain_name/privkey.pem
Restart Apache and Asterisk:
service apache restart
service asterisk restart
Verify HTTPS status in Asterisk:
asterisk -rx 'http show status'
Step 6: Download and Install ViciPhone
SSH to your Vicibox and run the following commands:
cd /var/tmp
git clone https://github.com/vicimikec/ViciPhone.git
cd Viciphone
cp -r src /srv/www/htdocs/agc/viciphone
chmod -R 755 /srv/www/htdocs/agc/viciphone
Step 7: Vicidial Configuration
Ensure the Vicidial admin interface is accessible via HTTPS. Update the Wephone URL in System settings:
https://192.168.0.201/vicidial/admin.php
Step 8: Configure External Server IP in Vicidial
Navigate to ADMIN -> Servers and configure the External Server IP and Web Socket URL:
Web Socket URL: wss://192.168.0.201:8089/ws
Step 9: Configure Vicidial Websocket Template
Go to Admin -> Templates and create a new template named "Web_phone". Paste the specified entries, adjusting the cert path:
Comments
Post a Comment