Home » Incredible PBX » Raspberry Pi

Category Archives: Raspberry Pi

The Most Versatile VoIP Provider: FREE PORTING

Introducing OSS Endpoint Manager for FreePBX 16 & Incredible PBX 2027


If you’ve been searching for a free, open source provisioning system for your SIP telephones and you’re using Incredible PBX 2027 or other FreePBX® 16 platforms, your prayers have been answered thanks to the hard work of Bill Simon. What this buys you (for free) is a quick way to configure SIP devices from most of the major players shown above including Aastra, AudioCodes, Cisco, Linksys, CloudTC, Digium, Grandstream, Intelbras, Mitel, Norphonic, Patton, Polycom, Snom, Thomson, Unidata, Xorcom, and Yealink.

To get started, log into FreePBX on your PBX platform and click on the Settings tab. If you see OSS Endpoint Manager as you will on most Incredible PBX 2027 installations, you can skip installing OSS Endpoint Manager and move on to the next step. Otherwise, here are the steps to install OSS EPM 16. Using SSH, log into your PBX as root and issue the following commands:

cd /var/www/html/admin/modules
wget https://filedn.com/lBgbGypMOdDm8PWOoOiBR7j/OSS-EPM/ossepm16.tgz
tar zxvf ossepm16.tgz
fwconsole ma install endpointman
rm -f /tmp/*
fwconsole reload 

Once you have OSS Endpoint Manager installed, return to the FreePBX GUI and open the application under the Settings tab. Read the reminder that you’re not using Sangoma’s commercial endpoint management product. Then click on the pull-down box in the right margin. Now let’s get the templates for the various SIP devices loaded onto your server.

  1. On the right pull-down, choose EndPoint Manager Settings.
  2. Adjust the entries as desired to set up your server as the host.
  3. For Package Server, enter: https://ossepm.incrediblepbx.com/
  4. Click in any other field to save your entries.
  5. On the right pull-down, choose Template Manager.
  6. Click the displayed link to download the latest templates from GitHub.
  7. On the right pull-down, choose Package Manager.
  8. Click Check for Updates.
  9. Click Install button beside each desired Brand.


The rest is a walk in the park. Plug in your SIP devices and perform the manufacturer’s steps to place the device in configuration mode. Insert the credentials to access OSS EPM on your PBX. Then sit back and enjoy the show.

Originally published: Thursday, February 1, 2024



Need help with Asterisk? Visit the VoIP-info Forum.


 

Special Thanks to Our Generous Sponsors


FULL DISCLOSURE: ClearlyIP, Skyetel, Vitelity, DigitalOcean, Vultr, VoIP.ms, 3CX, Sangoma, TelecomsXchange and VitalPBX have provided financial support to Nerd Vittles and our open source projects through advertising, referral revenue, and/or merchandise. As an Amazon Associate and Best Buy Affiliate, we also earn from qualifying purchases. We’ve chosen these providers not the other way around. Our decisions are based upon their corporate reputation and the quality of their offerings and pricing. Our recommendations regarding technology are reached without regard to financial compensation except in situations in which comparable products at comparable pricing are available from multiple sources. In this limited case, we support our sponsors because our sponsors support us.

BOGO Bonaza: Enjoy state-of-the-art VoIP service with a $10 credit and half-price SIP service on up to $500 of Skyetel trunking with free number porting when you fund your Skyetel account. No limits on number of simultaneous calls. Quadruple data center redundancy. $25 monthly minimum spend required. Tutorial and sign up details are here.

The lynchpin of Incredible PBX 2020 and beyond is ClearlyIP components which bring management of FreePBX modules and SIP phone integration to a level never before available with any other Asterisk distribution. And now you can configure and reconfigure your new Incredible PBX phones from the convenience of the Incredible PBX GUI.

VitalPBX is perhaps the fastest-growing PBX offering based upon Asterisk with an installed presence in more than 100 countries worldwide. VitalPBX has generously provided a customized White Label version of Incredible PBX tailored for use with all Incredible PBX and VitalPBX custom applications. Follow this link for a free test drive!
 

Special Thanks to Vitelity. Vitelity is now Voyant Communications and has halted new registrations for the time being. Our special thanks to Vitelity for their unwavering financial support over many years and to the many Nerd Vittles readers who continue to enjoy the benefits of their service offerings. We will keep everyone posted on further developments.
 



VoIP Messaging and The Golden Rule with Incredible PBX



If you want to continue to use SMS and MMS messaging on your VoIP platform, then today’s navigation guide is worth a careful read. Suffice it to say, this is what happens when the feds shirk their responsibilities and leave it to the foxes to guard the chicken coop.

The Golden Rule with all oligopolies is that he who has the gold makes the rules. And, make no mistake, there are stringent new rules for VoIP messaging. Not surprisingly, the FCC has jumped on the cellphone provider bandwagon. You can read all about the new FCC rules here. And the cellphone oligopoly has implemented additional requirements of its own that are enforced through a new organization called The Campaign Registry (TCR).

Any business that sends text messages to U.S. or Canadian mobile phone numbers is now required to register with TCR and obtain a 10-digit long code (10DLC) number. This number is used to identify the sender of each text message and to help the mobile carriers filter out spam (according to the carriers). To register with TCR, businesses must provide information about their company, including their legal name, EIN, and contact information. They must also submit a sample text message and identify the purpose for which they will be using SMS messaging.

What are TCR’s messaging guidelines?

  • Obtaining permission from recipients before sending them text messages
  • Clearly identifying the sender in each text message
  • Providing a way for recipients to opt out of receiving future text messages
  • Avoiding sending spam or unsolicited text messages

Carriers have imposed additional restrictions for certain types of messages so-called SHAFT content: sex, hate, alcohol, firearms, and tobacco (CBD is included). And, unlike email messages, SMS traffic cannot be encrypted so the providers can and do scan the contents of every message that hits their networks. If a business fails to comply with TCR’s requirements, the sender may face penalties including fines and suspension from sending text messages through the cellphone carriers.

You might wonder how these new rules came about. The short answer is that politicians flooded the cell providers’ networks with text messages during the last election cycle. And, of course, the politicians conveniently exempted themselves from all the spam rules including SMS messaging. So the new rules, while appearing admirable to the public, have little if anything to do with the root cause of the problem, the politicians.

CAUTION: What follows is NOT legal advice. It is simply our reading of available literature pertaining to TCR and VoIP.ms rules and regulations. Do NOT rely upon this interpretation of the rules in making decisions regarding SMS deployments. Do your own research. Better yet, consult an attorney.

Keep in mind that the current exception to TCR verification will probably disappear within the next several months. A word to the wise: Go ahead and get registered and verified unless you plan to use your cellphone exclusively for messaging or your usage is clearly non-business. The upfront costs are minimal. Here is an excellent summary of the various 10DLC registration categories.

Assuming your VoIP messages don’t include SHAFT content and otherwise comply with the guidelines above, there remains an exception for messaging without TCR verification… at least for now. The current limits on 10DLC SMS traffic without verification are as follows:

  • Daily limit: 500 message segments
  • Monthly limit: 5,000 message segments
  • Per-recipient limit: 10 messages per day

A message segment is equal to 158 characters. So, a single text message can be composed of one or more segments, depending on its length.

There’s one additional gotcha. For traditional 10-digit numbers, only one SMS segment per second can be sent, and it cannot be increased. So be brief. For toll-free numbers, three SMS segments per second can be sent, and the restriction can be relaxed under certain circumstances. For short code messaging (initial cost is usually $1,500 or more per month to obtain a short code), 100 SMS message segments per second are permitted, and this limit can also be increased.

Now let’s return to our Navigation Guide for those that simply want to use VoIP messaging in the traditional ways that used to work, i.e. for a coach to schedule a little league practice or for you to tell your kid you’re going to be late picking them up from school.

Rule #1: If you have enabled SMS messaging on all of your VoIP phone numbers, do not use numbers on which you depend for critical input for outbound SMS traffic. The risk you run is that breaking one of the rules or limits above may get your number blacklisted from ALL future SMS message traffic.

Rule #2: Don’t break the daily, monthly, and per-recipient messaging limits EVER.

Rule #3: Don’t send SHAFT content over SMS even if you’re joking. Big Brother does not have a sense of humor.

Rule #4: Keep messages under 158 characters in length unless you’re using a toll-free number (158×3 message size limit).

Rule #5: Don’t send more than one message per second. For example, if you’re using a script to send a team notice of a little league practice, be sure to insert a one or two-second pause between each outbound message.

Rule #6: Only use a throw-away number to send outbound SMS messages. If the number gets blacklisted, discard the number.

The Safest VoIP Messaging Platform


As you might expect, the safest way to send and receive SMS messages is through a cellphone or something that looks like a cellphone to the carrier networks. Our review of the Cudy Router spotlights a device that fits the bill perfectly if you have an extra SIM card lying around. Using the web interface on this device, you can send and receive SMS messages using the SMS link on the System Status page because the SMS messages appear to originate from a device on the cell provider’s own network where there are limited restrictions.

Using VoIP.ms for SMS Messaging

Assuming you can comply with all of the restrictions above, here’s our recommendation for a VoIP provider that lets you continue sending messages at minimal cost. That provider is one of our old favorites, VoIP.ms. Using our signup link helps keep the Nerd Vittles lights on so thank you in advance.

So long as you have an SMS-enabled DID with VoIP.ms, SMS messaging costs $0.0075 per message with no additional fees. Below we’ll walk you through getting everything set up with Incredible PBX to take advantage of VoIP.ms SMS services.

Configuring VoIP.ms for SMS Messaging

As noted, you’ll need to order a DID from VoIP.ms that supports SMS. Then enable SMS messaging in the DID setup and specify either an email address or cellphone number for delivery of incoming SMS messages addressed to that DID. If you happen to have a Yealink T46G (not T48G) or a Grandstream GXV phone that is also registered to that extension, the messages will also pop up on your desktop phone with an alert tone if you also enable "Link the SMS received to this DID to a SIP Account" and register the phone to a PJsip extension with the additions which follow. On Grandstream GXV Android phones, we recommend dragging the SMS app to the main screen so that the incoming message count appears beside the SMS icon when new messages are received. If you’re a clever programmer, you also can retrieve incoming messages from the Asterisk log by searching for "Inbound SMS dialplan invoked." The message will be in the following From and Body lines. Or tail /var/log/asterisk/full will look something like this:


To support sending SMS messages, enable the SOAP and REST/JSON API in the VoIP.ms Main Menu, set a very secure API password, and whitelist the IP addresses of each server from which you wish to send SMS messages.

Configuring Incredible PBX to Send SMS Messages

1. Login to your Incredible PBX 2027 server as root and issue the following commands:

cd /root/sms-voip.ms
rm -f /root/sms-voip.ms/*
pip install python-dotenv
wget http://incrediblepbx.com/sendsms-voipms.tar.gz
tar zxvf sendsms-voipms.tar.gz
rm sendsms-voipms.tar.gz
nano -w sendsms

2. When the editor opens, scroll down and replace 8431234567 with your SMS-enabled DID

3. Replace yourname@gmail.com with your VoIP.ms login email address

4. Replace your-API-key with your VoIP.ms API password

5. Save the file: Ctrl-X, Y, then ENTER

6. Send an SMS test message to your cell phone using the following syntax:

/root/sms-voip.ms/sendsms 10-digit-SMS-recipient "Your SMS message"

Configuring Incredible PBX to Receive SMS Messages

To receive SMS messages through FreePBX® using a compatible SIP phone or through the Asterisk CLI, you first must use a PJsip trunk to connect to VoIP.ms. Sample General Settings for the trunk are shown below. In the Advanced tab, set Message Context to sms-in.


You also must create a PJsip extension or use the preconfigured 701 PJsip extension. In the Advanced tab, set Message Context to sms-out.

Finally, edit extensions_custom.conf in /etc/asterisk and add the following code to the bottom of the file:

[sms-out]
exten => _.,1,NoOp(Outbound Message dialplan invoked)
exten => _.,n,NoOp(  TO: ${MESSAGE(to)})
exten => _.,n,NoOp(FROM: ${MESSAGE(from)})
exten => _.,n,NoOp(BODY: ${MESSAGE(body)})
;
; add your VoIPms info in the next 3 lines
exten => _.,n,Set(VOIPMS_ACCOUNT="123456_subacct")
exten => _.,n,Set(VOIPMS_POP="atlanta.voip.ms")
exten => _.,n,Set(VOIPMS_TRUNK="VoIPms-PJsip") ; actual VoIP.ms trunk in FreePBX
;
exten => _.,n,Set(NUMBER_TO=${CUT(CUT(MESSAGE(to),@,1),:,2)})
exten => _.,n,Set(EXTENSION_FROM=${CUT(CUT(MESSAGE(from),@,1),:,2)})
;
; Now map your sending extensions EXTENSION_FROM to corresponding DIDs NUMBER_FROM
exten => _.,n,Set(CASE_701=6005550101) ; ext 701 msgs originate from 6005550101
exten => _.,n,Set(CASE_702=6005550102) ; ext 702 msgs originate from 6005550102
exten => _.,n,Set(CASE_703=6005550101) ; ext 703 msgs originate from 6005550101
;
exten => _.,n,Set(NUMBER_FROM=${CASE_${EXTENSION_FROM}})
exten => _.,n,Set(ACTUAL_FROM="${NUMBER_FROM}" )
exten => _.,n,Set(ACTUAL_TO=pjsip:${VOIPMS_TRUNK}/sip:${NUMBER_TO}@${VOIPMS_POP})
exten => _.,n,MessageSend(${ACTUAL_TO},${ACTUAL_FROM})
exten => _.,n,NoOp(Send status is ${MESSAGE_SEND_STATUS})
exten => _.,n,Hangup()
;-------------------------------------------------------------------------

[sms-in]
exten => _.,1,NoOp(Inbound SMS dialplan invoked)
exten => _.,n,NoOp(  TO: ${MESSAGE(to)})
exten => _.,n,NoOp(FROM: ${MESSAGE(from)})
exten => _.,n,NoOp(BODY: ${MESSAGE(body)})
;
; enter your default incoming SMS extension below
; if you want SMS messages delivered to multiple extensions,
; clone additional MessageSend lines below with extension numbers
exten => _.,n,Set(EXTENSION=701)
;
exten => _.,n,Set(ACTUAL_FROM=${MESSAGE(from)})
exten => _.,n,Set(HOST_TO=${CUT(MESSAGE(to),@,2)})
exten => _.,n,Set(NUMBER_TO=${MESSAGE_DATA(X-SMS-To)})
exten => _.,n,MessageSend(pjsip:${EXTENSION}@${HOST_TO},${ACTUAL_FROM})
exten => _.,n,NoOp(Send status is ${MESSAGE_SEND_STATUS})
exten => _.,n,Hangup()
;-------------------------------------------------------------------------


In the pasted [sms-out] context, insert your actual VOIPMS_ACCOUNT, VOIPMS_POP, and VOIPMS_TRUNK name in the lines provided. Then map each extension from which you wish to send SMS messages to a VoIP.ms DID on your PBX in the lines provided. In the pasted [sms-in] context, enter the EXTENSION number which should receive incoming messages from the PJsip trunk in which you designated [sms-in] as the Message Context. There is no magic to the [sms-in] context name. If you have more than one PJsip trunk, simply create additional incoming contexts (such as [sms-in-2]) for each additional trunk and clone the [sms-in] code designating the desired extension to receive incoming messages from each DID. For the [sms-out] context, it can be used as the Message Context for multiple extensions that should be enabled to send outbound SMS messages.

Save the file, and reload the Asterisk dialplan: asterisk -rx "dialplan reload"

Introducing the FreePBX SMS Connector Module

Bill Simon recently released another messaging alternative with his SMS Connector Module for FreePBX. The beauty of his new approach is it lets you use Sangoma’s User Control Panel (UCP) to send and receive messages with Incredible PBX 2027. It also supports messaging on both Sangoma’s and ClearlyIP’s SIP phones including the Incredible PBX SIP phones. Here’s the setup process with Incredible PBX 2027 for non-business messaging using VoIP.ms.

At VoIP.ms…
1. Create a Subaccount and DID/Trunk
2. Enable SMS on the trunk and Link SMS Messages received on this Trunk to your SubAccount
3. Enable VoIP.ms API, create an API Password, and Whitelist the public IP address of your server
4. Copy your VoIP.ms email address and API Password for use on your server’s SMS setup

On Your Incredible PBX server…
1. Login to the FreePBX GUI as admin
2. Create a PJsip Trunk for VoIP.ms
3. In Advanced Settings, set Message Context to voipms-sms-in
4. In Admin -> User Management, create a password for extension 701
5. Add the following context to the end of /etc/asterisk/extensions_custom.conf:

[voipms-sms-in]
exten => _.,1,NoOp(Inbound Voip.ms SMS dialplan invoked)
same => n,Set(TO=${MESSAGE_DATA(X-SMS-To)})
same => n,Set(FROM=${CUT(MESSAGE(from),\",2)})
same => n,Set(ENV(QUERY_STRING)=provider=voipms\;to=${TO}\;from=${FROM}\;message=${URIENCODE(${MESSAGE(body)})})
same => n,Set(ENV(REQUEST_METHOD)=GET)
same => n,System(php /var/www/html/smsconn/provider.php)
same => n,Set(ENV(QUERY_STRING)=)
same => n,Hangup()
;-------------------------------------------------------------------------

6. Reload your dialplan: rm /tmp/* ; fwconsole reload

Install and Configure SMS Connector Module…
1. Login to your server as root and issue the following commands:

fwconsole ma downloadinstall https://filedn.com/lBgbGypMOdDm8PWOoOiBR7j/SMSconnector/smsconnector-16.0.11.tar.gz
fwconsole reload

2. In the FreePBX GUI, navigate to Connectivity -> SMS Connector
3. Click Provider Settings and enter your email address for Username and API Secret for VoIP.ms. Click Submit.
4. In SMS Connector menu, click Add Number and enter your DID and PJsip extension 701 to associate with it.
5. Enter VoIP.ms as Provider and click Save Changes.

Using User Control Panel (UCP)…
1. If you have not already done so, apply these UCP patches for Incredible PBX:

mysql -u root -ppassw0rd asterisk -e "update freepbx_settings set value = 'Latest-16' where keyword = 'MIRROR_BRAND_VERSION'; "
mysql -u root -ppassw0rd asterisk -e "update admin set value = 'true' where variable = 'need_reload'; "
rm -f /tmp/*
fwconsole reload
fwconsole ma downloadinstall ucp
rm -f /tmp/*
fwconsole reload

2. Open UCP from FreePBX GUI
3. Login as 701 with your new password
4. Click + in Upper Left of display and add SMS Module for 701.
5. When SMS Module appears on UCP console, click Start Conversation
6. Send a test message to your cellphone
7. Reply to the SMS message from your cellphone
8. Reply should appear in UCP within 20-30 seconds

Let’s close today with a final cautionary note. The Bell Sisters define non-business usage as conversational messaging much like what most already do using their cellphones. If you push the envelope, you risk $100 fines for every message sent. Unless you are a lawyer or have deep pockets to hire one and fight The Oligopoly, you are well advised to obtain a 10DLC number and avoid any potential issues going forward.

Originally published: Monday, November 6, 2023



Need help with Asterisk? Visit the VoIP-info Forum.


 

Special Thanks to Our Generous Sponsors


FULL DISCLOSURE: ClearlyIP, Skyetel, Vitelity, DigitalOcean, Vultr, VoIP.ms, 3CX, Sangoma, TelecomsXchange and VitalPBX have provided financial support to Nerd Vittles and our open source projects through advertising, referral revenue, and/or merchandise. As an Amazon Associate and Best Buy Affiliate, we also earn from qualifying purchases. We’ve chosen these providers not the other way around. Our decisions are based upon their corporate reputation and the quality of their offerings and pricing. Our recommendations regarding technology are reached without regard to financial compensation except in situations in which comparable products at comparable pricing are available from multiple sources. In this limited case, we support our sponsors because our sponsors support us.

BOGO Bonaza: Enjoy state-of-the-art VoIP service with a $10 credit and half-price SIP service on up to $500 of Skyetel trunking with free number porting when you fund your Skyetel account. No limits on number of simultaneous calls. Quadruple data center redundancy. $25 monthly minimum spend required. Tutorial and sign up details are here.

The lynchpin of Incredible PBX 2020 and beyond is ClearlyIP components which bring management of FreePBX modules and SIP phone integration to a level never before available with any other Asterisk distribution. And now you can configure and reconfigure your new Incredible PBX phones from the convenience of the Incredible PBX GUI.

VitalPBX is perhaps the fastest-growing PBX offering based upon Asterisk with an installed presence in more than 100 countries worldwide. VitalPBX has generously provided a customized White Label version of Incredible PBX tailored for use with all Incredible PBX and VitalPBX custom applications. Follow this link for a free test drive!
 

Special Thanks to Vitelity. Vitelity is now Voyant Communications and has halted new registrations for the time being. Our special thanks to Vitelity for their unwavering financial support over many years and to the many Nerd Vittles readers who continue to enjoy the benefits of their service offerings. We will keep everyone posted on further developments.
 



Incredible ChatGPT: Artificial Intelligence For Your Phone



Unless you’ve been sleeping under a rock, you already know that Artificial Intelligence (AI) has the potential to transform every aspect of our lives. The reasons are fairly obvious. AI can process and analyze massive amounts of data in seconds that humans could spend months and years collecting. AI is being used to develop new drugs and treatments, diagnose diseases, and provide personalized care to patients. It’s being used to develop self-driving cars and trucks, optimize traffic flows, and improve public transportation. It can be used in manufacturing to automate tasks, improve quality control, and reduce costs. And AI can be used in the financial world to detect fraud, assess risk, and make investment decisions. Because of AI’s encyclopedic prowess, it can also write a mean term paper with human-like prose. That’s the good news. The bad news is that not everything AI regurgitates is accurate so be extremely careful relying upon AI exclusively to make decisions. See if you can spot the problem in this ChatGPT response:
 


ChatGPT is a large language model chatbot developed by OpenAI, a company backed by Microsoft®. Within two months after launch, ChatGPT had over 100 million subscribers. It is trained on a massive dataset of text and code and is able to generate human-like text, translate languages, write different kinds of creative content, and answer your questions in an informative way. The knowledge cutoff date for the gpt-3.5-turbo version of ChatGPT is September 2021. For users of Incredible PBX, today we’re pleased to bring that ChatGPT model to a telephone near you.

To get started, you’ll need three components. First, you’ll need an Incredible PBX 2027 platform with Debian 11 or Ubuntu 22.04 running on Windows, a Mac, or Linux. Turnkey versions are available for dozens of virtual machine and cloud-based platforms. If you’re using Incredible PBX 2027 on the Rocky 8 platform, you will also need to install the gTTS text-to-speech engine from here. Second, you’ll need to obtain a free OpenAI_KEY here using your Google, Apple, or Microsoft email account. And, third, you’ll need to obtain a free Speech-to-Text API_KEY and API_URL from IBM. Once you have the three pieces in hand, you’re ready to proceed with the installation for your Incredible PBX platform. After installation, you can make ChatGPT queries using any telephone connected to your PBX. Simply dial 2428 (C-H-A-T) and speak your query.

Installing the ChatGPT Telephone Interface

Not every ChatGPT response is suitable for use with a telephone. You wouldn’t want ChatGPT reading you a term paper or spouting out some Asterisk® dialplan code. Nor can most telephones display photos. So our deployment for Incredible PBX today provides two ChatGPT solutions: (1) a command-line interface that is accessible from a terminal or via SSH: chatgpt -p "your query". (2) The telephone interface is accessible by dialing 2428. For the telephone interface, be careful what you ask. You don’t want a 10,000-word response. For example, a good query might be "What are the five best Atlantic coast beaches in the United States." A not-so-good query would be "What are the best restaurants in the world."

To get started after installing Incredible PBX using one of the numerous tutorials available here, log into your server as root and issue the following commands:

cd /
wget https://filedn.com/lBgbGypMOdDm8PWOoOiBR7j/ChatGPT/incredible-chat.tar.gz
tar zxvf incredible-chat.tar.gz
cd /root

Once the components have been downloaded and installed, navigate to the /root folder.
Enter your ChatGPT and IBM STT credentials in the following files:

  • Edit chat and insert your OPENAI_KEY in line 6
  • Edit chatgpt and insert your OPENAI_KEY in line 15
  • Edit chatgpt.sh and insert your OPENAI_KEY in line 12
  •  Also insert your IBM STT API_KEY in line 16 of chatgpt.sh
  •  Also insert your IBM STT API_URL in line 17 of chatgpt.sh

Complete the install by issuing the following commands:

cd /root
sed -i '/\[from-internal-custom\]/r chat.code' /etc/asterisk/extensions_custom.conf
chmod +x chat*
mv chat /usr/local/sbin
mv chatgpt /usr/local/bin
mv chatgpt.sh /var/lib/asterisk/agi-bin
asterisk -rx "dialplan reload"

NOTE: The chatgpt command-line tool does not work on the Rocky 8 platform because of a bug in their fold implementation. However, both our chat command-line tool and the 2428 telephony interface work fine once the gTTS text-to-speech engine is installed for Rocky 8.

Making a Test Call with ChatGPT

Now that all the pieces are in place, let’s make a test call. From a phone connected to your Incredible PBX server, dial 2428. At the prompt, enter the following query: What Are the Five Best Gulf Coast Beach Resorts in the United States? Within a minute or so, ChatGPT will provide the answer using the gTTS text-to-speech engine included in Incredible PBX. Enjoy!

A Cautionary Note About ChatGPT

We’ll close today with this cautionary note about ChatGPT… from ChatGPT:

Originally published: Friday, October 20, 2023



Need help with Asterisk? Visit the VoIP-info Forum.


 

Special Thanks to Our Generous Sponsors


FULL DISCLOSURE: ClearlyIP, Skyetel, Vitelity, DigitalOcean, Vultr, VoIP.ms, 3CX, Sangoma, TelecomsXchange and VitalPBX have provided financial support to Nerd Vittles and our open source projects through advertising, referral revenue, and/or merchandise. As an Amazon Associate and Best Buy Affiliate, we also earn from qualifying purchases. We’ve chosen these providers not the other way around. Our decisions are based upon their corporate reputation and the quality of their offerings and pricing. Our recommendations regarding technology are reached without regard to financial compensation except in situations in which comparable products at comparable pricing are available from multiple sources. In this limited case, we support our sponsors because our sponsors support us.

BOGO Bonaza: Enjoy state-of-the-art VoIP service with a $10 credit and half-price SIP service on up to $500 of Skyetel trunking with free number porting when you fund your Skyetel account. No limits on number of simultaneous calls. Quadruple data center redundancy. $25 monthly minimum spend required. Tutorial and sign up details are here.

The lynchpin of Incredible PBX 2020 and beyond is ClearlyIP components which bring management of FreePBX modules and SIP phone integration to a level never before available with any other Asterisk distribution. And now you can configure and reconfigure your new Incredible PBX phones from the convenience of the Incredible PBX GUI.

VitalPBX is perhaps the fastest-growing PBX offering based upon Asterisk with an installed presence in more than 100 countries worldwide. VitalPBX has generously provided a customized White Label version of Incredible PBX tailored for use with all Incredible PBX and VitalPBX custom applications. Follow this link for a free test drive!
 

Special Thanks to Vitelity. Vitelity is now Voyant Communications and has halted new registrations for the time being. Our special thanks to Vitelity for their unwavering financial support over many years and to the many Nerd Vittles readers who continue to enjoy the benefits of their service offerings. We will keep everyone posted on further developments.
 



Faxing Returns for Incredible PBX 2027 Platforms



As you may know, the introduction of Rocky 8, Debian 11, Ubuntu 22.04, and PHP 7.4 blew our HylaFax/AvantFax/IAXmodem faxing solution out of the water leaving all of the Incredible PBX 2027 builds with no fax capabilities. With some tips from our long-time contributor, Bill Simon, we are happy to report that an alternative solution is now available. It now provides BOTH incoming and outgoing fax support with email PDF delivery of all received faxes. While there are numerous free and paid options that support Outbound Faxing, we now have added an easy-to-use script that provides this functionality on Incredible PBX 2027 platforms.

Inbound Faxing Solution with Incredible PBX 2027

The new inbound faxing solution works much like it did with HylaFax and IAXmodem. You configure your Inbound Routes in FreePBX® to listen for fax tones. When an incoming fax is detected, the call is transferred to a SpanDSP fax context in Asterisk®. The incoming fax is then recorded as a .tiff image. When the recording is finished, we use the TIFF2PDF application to convert the image to a PDF file which is then emailed to a designated email address which you configure as part of this fax setup procedure. The prerequisite, of course, is to assure that Incredible PBX 2027 can send emails. This was covered in the initial setup tutorials, but we will repeat it below for slow learners.

Let’s first get your Incredible PBX 2027 platform configured to detect and process incoming fax calls. Log into your server as root and issue the following commands.

1. For Rocky 8 platforms: yum install libtiff && yum install libtiff-tools
    For Debian, Ubuntu, and Raspberry Pi platforms: apt install libtiff-tools -y

2. Issue the following commands to put the inbound fax context in place:

sed -i '/^\[custom-fax/,/^$/d' /etc/asterisk/extensions_custom.conf
echo '
[ext-group](+)
exten => fax,1,Noop(Fax detected)
exten -> fax,2,Goto(custom-fax-iaxmodem,s,1)

[custom-fax-iaxmodem]
exten => s,1,Answer
exten => s,n,Wait(1)
exten => s,n,Verbose(3,Incoming Fax)
exten => s,n,Set(FAXEMAIL=)     ; fax email address of recipient
exten => s,n,Set(FAXDEST=/tmp)  ; folder where faxes will be stored
exten => s,n,Set(tempfax=${STRFTIME(,,%C%y%m%d%H%M)})
exten => s,n,ReceiveFax(${FAXDEST}/${tempfax}.tif)
exten => s,n,System(/usr/bin/tiff2pdf -o "${FAXDEST}/${tempfax}.pdf" "${FAXDEST}/${tempfax}.tif")
exten => s,n,System(/usr/bin/echo "Incoming fax is attached." | /usr/bin/mail -s "Incoming FAX  Received" -A "${FAXDEST}/${tempfax}.pdf" "${FAXEMAIL}")
exten => s,n,Hangup

' >> /etc/asterisk/extensions_custom.conf

3. Update the fax context to include your email address for delivery of inbound faxes. Insert your email address in the code below replacing yourname@gmail.com:

sed -i 's|FAXEMAIL=|FAXEMAIL=yourname@gmail.com|' /etc/asterisk/extensions_custom.conf

4. Download and install the Fax module for FreePBX:

fwconsole ma downloadinstall fax
rm /tmp/*
fwconsole reload

5. Open the FreePBX GUI and check to be sure you still have a Custom Destination called Fax (HylaFax). If not, create it:

Target: custom-fax-iaxmodem,s,1
Description: Fax (HylaFax)
Return: No

6. In the FreePBX GUI, modify each of your Inbound Routes to support incoming faxes from the DIDs you’ll be using for inbound faxes. In the new Fax tab, edit the settings as shown below, save the settings, and reload your dialplan.

 Yes
 SIP
 No
 5
 Custom Destinations
  Fax (HylaFax)

7. Be sure you have configured Outbound Email with SendMail using the instructions below before continuing.

8. Send a test fax from FaxZero to one of your fax-enabled DID’s while watching the Linux CLI for issues.


Configuring Gmail as Smart Relay Host

Most Incredible PBX implementations will be on networks managed by companies like Comcast, Spectrum, and AT&T that block downstream mail servers (that’s you) from sending email. The solution is to use Gmail or your local ISP as a smart relay host to send mail from your server. You’ll need this to deliver voicemails and faxes via email. Here’s how to set it up using a Gmail account.

IMPORTANT: You MUST obtain and use a Gmail App Password instead of your Gmail account password when running the script below. If you’re a Google hater, here’s an alternative.

/root/enable-gmail-smarthost-for-sendmail

Now send yourself a test email message to make sure things are working properly:

echo "test" | mail -s testmessage yourname@yourmailprovider.com

Outbound Faxing Solutions with Incredible PBX 2027

We’ve now developed a sendfax.sh script for use on Incredible PBX 2027 platforms. It lets you send any PDF document as a fax by simply copying the file to the /tmp directory and running the sendfax.sh script. You’ll be prompted for the name of the PDF file to send, the trunk to use for the call, and the phone number of the destination fax in the format required by your designated trunk. Make certain that you have provided the appropriate CallerID number in your Trunk setup, or the outbound calls may fail. After you complete the steps above to enable Inbound Faxing, issue the following commands to install this new Outbound Faxing addition:

cd /root
wget http://incrediblepbx.com/sendfax2027.tar.gz
tar zxvf sendfax2027.tar.gz
rm -f sendfax2027.tar.gz

Now let’s be sure your platform has the necessary components to support Outbound Faxing.

On Rocky 8 platforms, issue the following commands:

yum install libtiff
yum install libtiff-tools
yum install ghostscript

On Debian, Ubuntu and Raspberry Pi platforms, issue the following commands:

 apt update
 apt install libtiff-tools -y
 apt install ghostscript -y
 

Next edit /root/sendfax.sh and enter the callerid, faxheader, and faxstationid for your new Outbound Faxing Engine.

Disable the messages prompting for these components by issuing the command:
touch /etc/pbx/.sendfax

Finally, for installs before 9/27/2023, if you will be using a PJsip trunk to send outbound faxes, issue the following command to adjust the syntax in the sendfax.sh script. This is automatic for new installs.

sed -i 's|SIP/$mytrunk/$faxnumber|PJSIP/$faxnumber@$mytrunk|' /root/sendfax.sh

Now you’re ready to take Outbound Faxing for a test drive. Deposit a PDF file in the /tmp directory of your server. Then issue the following command to begin the Outbound Faxing process: /root/sendfax.sh. When prompted, enter the file name of your PDF file, the trunk name which will be used to make the call, and the phone number for the fax destination. That’s all the setup that’s required.

When you run the script, it will stay active until the fax has been delivered in order to alert you as to whether the fax transmission was successful. If, for some reason, the fax transmission fails, you can resend it with the following commands:

cp -ap /root/sendfax.call /tmp/cf
rm -f /var/spool/asterisk/outgoing_done/cf
mv /tmp/cf /var/spool/asterisk/outgoing/

You can verify receipt of the new fax attempt by waiting a reasonable time and then issuing these commands:

cd /var/spool/asterisk/outgoing_done
date -d @`cat cf | grep StartRetry | cut -f 2 -d "(" | cut -f 1 -d ")"`
cat cf | grep Status


While it is no longer possible to send faxes directly using AvantFax, there are some additional alternatives. A free one is faxzero.com, which lets you send 5 free faxes a day with up to 3 pages of text plus a cover sheet. A second alternative for infrequent use is to pay FaxZero $2.09 per fax to send up to 25 pages with an optional cover page. Another option is to send and receive faxes from your computer or mobile phone using a dedicated fax number from a service such as FaxDeck. Outbound faxing works almost identically to AvantFax. FaxDeck lets you send and receive up to 300 pages to the U.S. and Canada for $5 a month. Or, for $10 a month, you can send and receive up to 1,000 pages. That’s a penny per page which is less than the cost of most VoIP calls. Many of our recommended providers including Skyetel, ClearlyIP, VoIP.ms, and Vitelity also offer dedicated fax numbers as well as email-to-fax solutions.

Originally published: Monday, January 30, 2023    Updated: September 27, 2023



Need help with Asterisk? Visit the VoIP-info Forum.


 

Special Thanks to Our Generous Sponsors


FULL DISCLOSURE: ClearlyIP, Skyetel, Vitelity, DigitalOcean, Vultr, VoIP.ms, 3CX, Sangoma, TelecomsXchange and VitalPBX have provided financial support to Nerd Vittles and our open source projects through advertising, referral revenue, and/or merchandise. As an Amazon Associate and Best Buy Affiliate, we also earn from qualifying purchases. We’ve chosen these providers not the other way around. Our decisions are based upon their corporate reputation and the quality of their offerings and pricing. Our recommendations regarding technology are reached without regard to financial compensation except in situations in which comparable products at comparable pricing are available from multiple sources. In this limited case, we support our sponsors because our sponsors support us.

BOGO Bonaza: Enjoy state-of-the-art VoIP service with a $10 credit and half-price SIP service on up to $500 of Skyetel trunking with free number porting when you fund your Skyetel account. No limits on number of simultaneous calls. Quadruple data center redundancy. $25 monthly minimum spend required. Tutorial and sign up details are here.

The lynchpin of Incredible PBX 2020 and beyond is ClearlyIP components which bring management of FreePBX modules and SIP phone integration to a level never before available with any other Asterisk distribution. And now you can configure and reconfigure your new Incredible PBX phones from the convenience of the Incredible PBX GUI.

VitalPBX is perhaps the fastest-growing PBX offering based upon Asterisk with an installed presence in more than 100 countries worldwide. VitalPBX has generously provided a customized White Label version of Incredible PBX tailored for use with all Incredible PBX and VitalPBX custom applications. Follow this link for a free test drive!
 

Special Thanks to Vitelity. Vitelity is now Voyant Communications and has halted new registrations for the time being. Our special thanks to Vitelity for their unwavering financial support over many years and to the many Nerd Vittles readers who continue to enjoy the benefits of their service offerings. We will keep everyone posted on further developments.
 



What A Steal: Host Unlimited Email Domains for Life



In these inflationary times, it’s always refreshing to find a technology solution that has actually decreased in price. To combat spam, hosting providers including Comcast and Spectrum have made it next to impossible to deploy a downstream mail server. So a relay hosting solution has become a must-have for VoIP server platforms including Incredible PBX. We’re thrilled to introduce MXroute’s $129 lifetime, cloud-based email hosting solution which supports unlimited domains, unlimited email addresses, and 10GB of storage. But you better hurry. This special won’t last long.

To get started with MXroute, you’ll want to spend some time in their tutorials making sure that you’ve properly configured DNS for the email domains you wish to host on MXroute. Pay particular attention to resolving DMARC, DKIM, and SPF issues before you go live. MXroute’s DNS support documentation is second to none.

For our part, we’ll show you how to configure Incredible PBX 2027 with Debian 11 or Ubuntu 22.04 to use MXroute as your email relay host so that email messages leave your server and arrive at their intended destinations without a hiccup or a SPAM flag. By default, Incredible PBX 2027-D and 2027-U servers are shipped with SendMail preconfigured and an enable-gmail-smarthost-for-sendmail script. Running the script assures proper delivery of outbound email so long as you use an existing Gmail account with a generated App password. But many prefer to cut the cord to Google and host their own email accounts, and that’s where we begin today.

To get started, sign up for an MXroute Unlimited Account. With your credentials in hand, log into the DirectAdmin web portal. Create your first email domain in Account Manager -> Domain Setup. Next, drop down to Email Manager -> Email Accounts and create an email account for the domain you created. Make note of the account password you use because you can’t retrieve it after you leave the creation step. You’ll see an arrow beside the newly created email account. It will take you to a functioning, web-based email client without having to enter your email account’s password. This email client can be used to send out test messages after you get the DNS settings for your domain squared away. Don’t continue with the Incredible PBX server setup below until you can successfully send and deliver a message from within the web-based email client with at least DKIM and SPF showing as PASSED in the original message listing for the delivered email message.

Incredible PBX Using MXroute As Smart Relayhost

What follows has been tested on Incredible PBX 2027 platforms deployed with Debian 11 or Ubuntu 22.04. It will not work with RedHat, CentOS, or Rocky 8 platforms which we no longer support. See this post for RedHat tips. Configuring your server to use MXroute as a smart relay host is a two-step process. First, we’ll replace SendMail with Postfix. And then we’ll set up MXroute as your email relay to avoid issues sending email from servers downstream from your Internet Service Provider, a.k.a. Comcast or Spectrum among others.

Replacing SendMail with Postfix on Incredible PBX

Begin by logging into your Incredible PBX server as root. Then issue the following commands:

systemctl stop sendmail
systemctl disable sendmail
apt-get update
apt-get install postfix sasl2-bin libsasl2-modules -y
dpkg-reconfigure postfix
# choose NO Configuration option
systemctl start postfix
systemctl enable postfix
sed -i 's|-c sendmail|-c postfix|' /usr/local/sbin/pbxstatus
echo "incrediblepbx.com" > /etc/mailname
sed -i 's|SendMail| Postfix|' /usr/local/sbin/pbxstatus
systemctl status postfix

Deploying MXroute with Postfix

You’ll need three pieces of information to deploy MXroute as a smart relayhost with Incredible PBX: the name of your MXroute server (e.g. friday.mxrouting.net) and both the email address and password of an active account on MXroute (e.g. myname@mydomain.com & mypassword).

With these in hand, edit and save /etc/postfix/main.cf after adding the following to the bottom of the file using your actual MXroute server name in the first line. Leave the brackets in place.

relayhost = [friday.mxrouting.net]:587
smtp_use_tls = yes
smtp_tls_security_level = encrypt
smtp_sasl_tls_security_options = noanonymous
smtp_sasl_auth_enable = yes
smtp_sasl_security_options = noanonymous
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_tls_CAfile = /etc/ssl/certs/ca-certificates.crt
header_size_limit = 4096000

Next, create an /etc/postfix/sasl_passwd file with your three credentials:

[friday.mxrouting.net]:587	myname@mydomain.com:mypassword

Finally, issue the following commands to complete the setup:

chmod 600 /etc/postfix/sasl_passwd
postmap /etc/postfix
postmap /etc/postfix/sasl_passwd
systemctl restart postfix
systemctl status postfix

Testing Email with MXroute and Postfix

As a security precaution, you can only send emails through MXroute using the email address registered with Postfix as your Reply-TO address. From the command line, your outbound email should look like this:

echo "test" | mail -r myname@mydomain.com -s testmsg somebody@somewhere.com 

Also be sure to adjust the FROM address for outbound voicemail messages in the FreePBX GUI. Login as admin and enter your Sender Identity Email Address in the Server Email field in Settings -> Voicemail Admin -> Settings -> Email Config.

Originally published: Monday, September 25, 2023



Need help with Asterisk? Visit the VoIP-info Forum.


 

Special Thanks to Our Generous Sponsors


FULL DISCLOSURE: ClearlyIP, Skyetel, Vitelity, DigitalOcean, Vultr, VoIP.ms, 3CX, Sangoma, TelecomsXchange and VitalPBX have provided financial support to Nerd Vittles and our open source projects through advertising, referral revenue, and/or merchandise. As an Amazon Associate and Best Buy Affiliate, we also earn from qualifying purchases. We’ve chosen these providers not the other way around. Our decisions are based upon their corporate reputation and the quality of their offerings and pricing. Our recommendations regarding technology are reached without regard to financial compensation except in situations in which comparable products at comparable pricing are available from multiple sources. In this limited case, we support our sponsors because our sponsors support us.

BOGO Bonaza: Enjoy state-of-the-art VoIP service with a $10 credit and half-price SIP service on up to $500 of Skyetel trunking with free number porting when you fund your Skyetel account. No limits on number of simultaneous calls. Quadruple data center redundancy. $25 monthly minimum spend required. Tutorial and sign up details are here.

The lynchpin of Incredible PBX 2020 and beyond is ClearlyIP components which bring management of FreePBX modules and SIP phone integration to a level never before available with any other Asterisk distribution. And now you can configure and reconfigure your new Incredible PBX phones from the convenience of the Incredible PBX GUI.

VitalPBX is perhaps the fastest-growing PBX offering based upon Asterisk with an installed presence in more than 100 countries worldwide. VitalPBX has generously provided a customized White Label version of Incredible PBX tailored for use with all Incredible PBX and VitalPBX custom applications. Follow this link for a free test drive!
 

Special Thanks to Vitelity. Vitelity is now Voyant Communications and has halted new registrations for the time being. Our special thanks to Vitelity for their unwavering financial support over many years and to the many Nerd Vittles readers who continue to enjoy the benefits of their service offerings. We will keep everyone posted on further developments.
 



Zero-Day Vulnerabilities Compromise All FreePBX Systems



If you’re a user of Asterisk® and FreePBX®, the DEFCON 31 Conference in Las Vegas did not disappoint this year. It exposed not one but three critical, unpatched vulnerabilities in affected FreePBX-based platforms that can compromise your servers in under a minute. I would hasten to add that all of these vulnerabilities were disclosed to Sangoma® months ago and remain unaddressed for months. What this meant was a hacker could easily get administrator privileges on your server with a blank check to make free calls on your nickel or further infect your server with additional hidden components.




 

How Vulnerable Are You? Here’s a quick summary of the bugs documented in the presentation above. If you expose a port on your server to configure SIP phones, you’re compromised. If your users have public IP access to the User Control Panel (UCP), you’re compromised. Any user can delete any asterisk-owned file from your server. Use a Digium® or Sangoma® VoIP phone? You’re compromised. Actually, all you need is the MAC address of one of these phones and its password login and the User-Agent header of any Digium Phone (Digium D60 2_7_0), and you’re compromised if the dphone API RestApp is running on your server. Are you running the API module in FreePBX with public IP address access to your server? You’re compromised because of a bug in the generateDocumentation function. These are classic command injection and authentication bypass issues in FreePBX that can even be triggered from the bad guys’ servers using generated access tokens.


Sangoma, Sangoma. Wherefore Art Thou? You can read all about Sangoma’s Bug Bounty Program here. It was conveniently deleted immediately after this zero-day vulnerability was reported. We’ve reproduced the page from the Wayback Machine. So what happened? According to the good pseudonym researcher, not much. Aside from an initial response indicating that the bugs had been addressed, there was never a follow-up response when the researcher advised that the patches did not work.




 

What Can You Do? Your safest bet is to switch to a security model that does not expose your server or its assets to the public Internet. Incredible PBX is an out-of-the-box platform that provides this security. It’s available for Rocky 8 (not recommended), Debian 11, Ubuntu 22.04 as well as virtualization platforms including VirtualBox, VMware, Proxmox, Windows WSLg, LXC Linux Containers, and Apple’s UTM platform. OpenVPN is also strongly recommended.

At the very minimum, put your server behind a hardware-based firewall with no public Internet exposure until these bugs are properly resolved. You’ve been warned!

Follow updated comments on this issue on the FreePBX Forum and the VoIP-info.org Forum.

Originally published: Sunday, September 17, 2023    Updated: October 13, 2023



Need help with Asterisk? Visit the VoIP-info Forum.


 

Special Thanks to Our Generous Sponsors


FULL DISCLOSURE: ClearlyIP, Skyetel, Vitelity, DigitalOcean, Vultr, VoIP.ms, 3CX, Sangoma, TelecomsXchange and VitalPBX have provided financial support to Nerd Vittles and our open source projects through advertising, referral revenue, and/or merchandise. As an Amazon Associate and Best Buy Affiliate, we also earn from qualifying purchases. We’ve chosen these providers not the other way around. Our decisions are based upon their corporate reputation and the quality of their offerings and pricing. Our recommendations regarding technology are reached without regard to financial compensation except in situations in which comparable products at comparable pricing are available from multiple sources. In this limited case, we support our sponsors because our sponsors support us.

BOGO Bonaza: Enjoy state-of-the-art VoIP service with a $10 credit and half-price SIP service on up to $500 of Skyetel trunking with free number porting when you fund your Skyetel account. No limits on number of simultaneous calls. Quadruple data center redundancy. $25 monthly minimum spend required. Tutorial and sign up details are here.

The lynchpin of Incredible PBX 2020 and beyond is ClearlyIP components which bring management of FreePBX modules and SIP phone integration to a level never before available with any other Asterisk distribution. And now you can configure and reconfigure your new Incredible PBX phones from the convenience of the Incredible PBX GUI.

VitalPBX is perhaps the fastest-growing PBX offering based upon Asterisk with an installed presence in more than 100 countries worldwide. VitalPBX has generously provided a customized White Label version of Incredible PBX tailored for use with all Incredible PBX and VitalPBX custom applications. Follow this link for a free test drive!
 

Special Thanks to Vitelity. Vitelity is now Voyant Communications and has halted new registrations for the time being. Our special thanks to Vitelity for their unwavering financial support over many years and to the many Nerd Vittles readers who continue to enjoy the benefits of their service offerings. We will keep everyone posted on further developments.
 



Adding Incredible PBX Goodies & More to VitalPBX 4



As continued use of FreePBX® becomes more and more precarious because of deprecated components and looming incompatibility with Asterisk® 21, the appeal of 3CX and VitalPBX as a VoIP platform becomes increasingly compelling. Whether you’re a home user, a small business, or a call center, VitalPBX provides a solution to meet your requirements. To make the transition a bit less painful, today we introduce a number of popular Incredible PBX applications for VitalPBX 4. And, as always, all of the Incredible PBX additions are free, open source, and GPL code.


If you’re unfamiliar with the VitalPBX VoIP platform, here are some features that may be of interest. First, it runs on the latest Debian 11 platform and is Asterisk-based freeware with optional commercial components. Most GPL applications designed for FreePBX will run equally well under VitalPBX without modification. Second, VitalPBX provides multi-tenant functionality with the purchase of a commercial module. Third, VitalPBX supports Asterisk High Availability (HA) failover at no cost using an open source script provided by the VitalPBX developers. Complete tutorial here. Compare this to the FreePBX HA offering which retails for $1,500. Commercial modules offer Microsoft Teams integration as well as the full complement of Sonata Suite Call Center offerings: Billing, Switchboard, Stats, Dialer, and Recordings. Faxing, Paging, Queues Callback, and Phone Provisioning modules are also available at modest cost. Keep reading if any of these are of interest to you.


Getting Started with VitalPBX

Before you can install VitalPBX applications, you’ll obviously need a VitalPBX server. You can build the platform with on-premise hardware, or in the cloud using one of our recommended providers, or on a Raspberry Pi. We recommend at least 4GB of RAM and at least a 30GB disk. Two gigs of RAM will suffice with a 2GB swap file. VitalPBX can be deployed using the VitalPBX ISO, or you can start with a fresh Debian 11 platform and then run the VitalPBX install script:

wget https://repo.vitalpbx.com/vitalpbx/v4/apt/debian_vpbx_installer.sh
chmod +x debian_vpbx_installer.sh
apt install sudo
./debian_vpbx_installer.sh

For Raspberry Pi deployments, here are the steps using a 32GB microSD card:

Begin by downloading Raspberry Pi Imager for PC, MAC, or Ubuntu desktop. Run the Imager from your desktop computer with the following settings after inserting your 32GB microSD card into your desktop machine (see the sidebar for an inexpensive microSD/USB device):

OS: Raspberry Pi OS (other) -> Raspberry Pi OS Lite (64-bit)
Storage: Select your microSD card (32GB Type 10 recommended)
Click WRITE

Remove the microSD card from your desktop computer. Insert it into your Raspberry Pi and power on the device. The initial Raspberry Pi OS setup for the United States follows. For users elsewhere, follow your nose.

Choose keyboard layout: (Other, English (US) for USA users)
Keyboard Layout: English (US)
username: nerd
password: make it secure, type it twice
login: nerd with new password
sudo passwd root
create new secure root password
logout: exit
login: root with new root password
userdel nerd
nano -w /etc/ssh/sshd_config
  edit and uncomment: PermitRootLogin yes
  uncomment PasswordAuthentication yes
  save: Ctrl-X, Y, then ENTER key
run: raspi-config
  Settings Apply to: pi
  Localization: WLAN Country: US
  System Options: Wireless LAN: Enter your SSID and SSID passphrase
  System Options: Hostname: debian
  System Options: Power LED: YES
  Interface Options: SSH: YES
  Localization: Locale: Disable en_GB.UTF-8 and Enable en_US.UTF-8
  Localization: TimeZone: America, NewYork
  FINISH and Reboot

Once your Raspberry Pi has restarted, login as root with your root password and run the debian_vpbx_installer.sh script from above.

Adding a Whitelist & Hardening Your Firewall

We’ve built firewall whitelist rules for some of our favorite providers: Skyetel, BulkVS, VoIP.ms, Acrobits, SignalWire, Nexmo, Callcentric, and Anveo Direct. Also included are all private LAN, non-routable IP addresses and the default OpenVPN addresses. Issuing the following commands will install this whitelist and overwrite your existing firewall whitelist, if any. WARNING: The existing VitalPBX Firewall exposes all of your SIP ports as well as SSH, HTTP, and HTTPS so deploy VitalPBX behind a hardware-based firewall unless you significantly harden the VitalPBX Firewall ports. If you’re sure you’ve whitelisted the IP addresses of all your remote PCs, extensions, and trunk providers in Admin -> Firewall -> Access Control, then you can harden your firewall and protect your server by deleting the following entries in Admin -> Firewall -> Rules: HTTP, HTTPS, SSH, PJSIP, SIP, and IAX2. Then test all your connections to make certain they still are accessible. For future additions, we strongly recommend using OpenVPN addresses which require no new Firewall additions.

cd /root
wget https://filedn.com/lBgbGypMOdDm8PWOoOiBR7j/VitalPBX-4/whitelist.sql
mysql -u root ombutel < whitelist.sql
vitalpbx apply-firewall
iptables -nL

gTTS Text-to-Speech Engine for VitalPBX

We've tested and implemented at least a half dozen text-to-speech engines to support Asterisk applications including Festival, FLITE, Amazon's Polly, IBM's Bluemix TTS, Pico TTS, and more. None are better than Google's free gTTS engine. Here's how to deploy it with VitalPBX to support all of your applications requiring TTS support. Login to your server as root and issue the following commands:

apt-get update
apt-get -y install jq libsox-fmt-all
apt-get -y install python3-pip
pip install --upgrade pip
pip3 install --upgrade pip
ln -s /usr/bin/pip3 /usr/bin/pip
pip install gTTS

Adding Custom Contexts Support to VitalPBX

In addition to the commercial modules, there are a number of free VitalPBX add-ons, one of which is Custom Contexts. We would recommend adding all of the free ones to get started. After logging into the web interface as admin, navigate to Admin -> Add-ons -> Add-ons. Click the Check Online button to load the latest available add-ons. Then click the Install icon for the following add-ons: System API, Authentication Codes, Bulk Extensions, Custom Contexts, Phone Books, and Task Manager. Once these add-ons are installed, you can install the following components.


Adding Incredible PBX Starter Kit to VitalPBX

We've put together a collection of some of our favorite Incredible PBX applications to enhance the VitalPBX platform. These include telephone apps like Yahoo News Headlines (dial 951), NWS Weather Reports by ZIP Code (947), Today in History (86329), and Telephone Reminders (123). In addition, we've reworked the pbxstatus utility (above) which will display whenever you log into your server as root from the Linux command line.

Many of these applications rely upon the gTTS text-to-speech engine so be sure you install it before proceeding.

To install the Incredible PBX collection, log into your server as root and issue the following commands:

cd /etc/asterisk/vitalpbx
cp extensions__80-IncrediblePBX.conf /root/extensions__80-IncrediblePBX.conf.bak
cd /
wget https://filedn.com/lBgbGypMOdDm8PWOoOiBR7j/VitalPBX-4/incrediblepbx.tar.gz
tar zxvf incrediblepbx.tar.gz
rm -f incrediblepbx.tar.gz
asterisk -rx "dialplan reload"
echo "0 0 * * * root /var/lib/asterisk/agi-bin/run_recurring >/dev/null 2>&1" >> /etc/crontab
echo "3 0 * * * root /var/lib/asterisk/agi-bin/run_reminders >/dev/null 2>&1" >> /etc/crontab

Using Telephone Reminders with VitalPBX

Nerd Vittles Telephone Reminder System has been reworked for VitalPBX 4 and PHP 8.1. It lets you schedule reminders for future events (at least 4 minutes in the future) by telephone by dialing 123. When the appointed date and time arrives, Asterisk swings into action and places a call to the number you designate to deliver a customized reminder message. Recurring reminders also are supported. You can set up reminders that place calls daily or on weekdays as well as weekly, monthly, and annually. This means it can be used to wake you up in the morning, or to remind Granny to take her medicine every day, or to remind your Little League team of practice times and locations, or to remind you and your customers of scheduled and recurring events. External reminder calls are supported using your default outbound route's dial string, e.g. NXX-NXX-XXXX.

The complete tutorial for Telephone Reminders 4 is available here. The web interface is not yet supported on the VitalPBX platform; however, this Telephone Reminders app adds features that are not available in the *38 offering included in the VitalPBX Feature Code listing. Among these are optional recurring reminders as well as the ability to revise your reminder message before actually scheduling it.

Headline News & Weather Forecasts & Today in History

These three applications are self-explanatory. The best way to learn about them is to dial the three extensions from any phone registered on your VitalPBX server: Headline News (dial 951), Weather Forecasts by ZIP Code (dial 947), and Today in History (dial T-O-D-A-Y)

Adding OpenVPN to VitalPBX

The most secure method for accessing VitalPBX is to place your server behind a hardware-based firewall and use OpenVPN from the client PCs and phones to access the server. VitalPBX includes an OpenVPN add-on that includes both a server and a free 2-client license. For unlimited clients, you can purchase the commercial module for $120. In the alternative, you can deploy your own OpenVPN server and clients using this Nerd Vittles tutorial for Debian.

If you already have an OpenVPN server in operation, create an OpenVPN client for VitalPBX and name it incrediblepbx.ovpn. Copy it into the /etc directory of your VitalPBX server. Then issue the following commands and reboot to activate OpenVPN on your VitalPBX server:

apt-get update
apt-get -y install openvpn unzip
cd /
wget https://filedn.com/lBgbGypMOdDm8PWOoOiBR7j/VitalPBX-4/openvpn-vitalpbx.tar.gz
tar zxvf openvpn-vitalpbx.tar.gz
rm -f openvpn-vitalpbx.tar.gz
shutdown -r now

Getting Started with Faxing

If your deployment is for a home or home office, then VitalPBX offers a free faxing component for a single trunk. We've tested this with VoIP.ms, and it works flawlessly. Begin by enabling the Virtual Faxes module. For your Trunk, enable FAX Detection and T.38, if desired. For your Fax Device, provide a Description, Destination Email, and CallerID Name and Number. For your Inbound Route, enable Fax Detection and Fax Destination of Fax Devices selecting the Destination Description you assigned to your Fax Device. Now place a test call to your DID from FaxZero.com. The Fax Sending module worked equally well.

Adding CallerID Names for Incoming Calls

Legal Disclaimer: Most CNAM providers have restrictions regarding caching of CNAM data. The courts consistently have ruled that phonebook data is not copyrightable. And every PBX caches CNAM data. After all, that's what CDR logs are all about. Consult with your own attorney if you have concerns, or simply stop reading here. 🙂

Some providers of DIDs also offer CallerID Name (CNAM) service for incoming calls. With VoIP.ms, it's optional and costs $0.008 per call. With BulkVS, it's mandatory and costs $0.003 per call. With many DID providers, you will only receive the CallerID Number on incoming calls. Thus was born our CallerID Trifecta and later Superfecta add-ons many years ago. Most of the free sources from yesteryear have disappeared, and we've only found two commercial sources that are reasonably priced at $0.003 per call: BulkCNAM (from the BulkVS folks) and EZCNAM at same price with a 25¢ credit to let you try out their service. Both work well.

Once you have installed Custom Context module for VitalPBX as well as the Incredible PBX Starter Kit from above, here are the steps to implement CNAM lookups on your incoming calls. First, sign up for an account with one or both of the providers and obtain a SOAP API Key from BulkCNAM or a traditional API key from EZcnam. Then login to your server as root and create an executable install script using the following template for BulkCNAM:

cd /root
rm -f superfecta-bulkcnam
wget https://filedn.com/lBgbGypMOdDm8PWOoOiBR7j/VitalPBX-4/superfecta-bulkcnam
sed -i 's|SOAP-API-KEY|actual-key|' superfecta-bulkcnam
sed -i '\:// BEGIN CallerID Superfecta:,\:// END CallerID Superfecta:d' /etc/asterisk/vitalpbx/extensions__80-IncrediblePBX.conf
cat superfecta-bulkcnam >> /etc/asterisk/vitalpbx/extensions__80-IncrediblePBX.conf
asterisk -rx "dialplan reload"


Or create an executable install script using the following template for EZCNAM:

cd /root
rm -f superfecta-ezcnam
wget https://filedn.com/lBgbGypMOdDm8PWOoOiBR7j/VitalPBX-4/superfecta-ezcnam
sed -i 's|=API-KEY|=actual-key|' superfecta-ezcnam
sed -i '\:// BEGIN CallerID Superfecta:,\:// END CallerID Superfecta:d' /etc/asterisk/vitalpbx/extensions__80-IncrediblePBX.conf
cat superfecta-ezcnam >> /etc/asterisk/vitalpbx/extensions__80-IncrediblePBX.conf
asterisk -rx "dialplan reload"


In your install script of choice, replace actual-key with the SOAP API key or API key you obtained from the provider. Make the script executable (chmod +x) and then run it to install the new script in your dialplan. Then reload dialplan: asterisk -rx "dialplan reload"

As deployed, the [superfecta] context assumes you want incoming calls routed to extension 501. You can modify this in /etc/asterisk/vitalpbx/extensions__80-IncrediblePBX.conf and reload your dialplan.

In the VitalPBX GUI, login as admin and navigate to PBX -> Applications -> Custom Contexts and create a new Custom Context and reload the dialplan:

Description: CallerID Superfecta
Context: superfecta
Extension: s
Priority: 1

Destination:

Custom Contexts -> Incredible PBX

In PBX -> Calls Routing -> Inbound Routes, edit your existing Inbound Route for your incoming DID and set the Inbound Destination to: Custom Contexts -> CallerID Superfecta. Then reload your dialplan.

How It Works: When an incoming call from a new caller is detected, the Superfecta script will greet the caller and ask the caller to press 7. Once the caller presses 7, the Superfecta script will look up the CNAM entry matching the CallerID Number and then route the call to extension 501. Successful callers are whitelisted and logged in the Asterisk database: database show cidname. When the same caller calls again, the call will be routed to extension 501 without prompting to press 7. Additional routing options are available by editing the [superfecta] context.

Configuring Gmail as SMTP Relay Host

The VitalPBX Portal includes the option to configure either a self-hosted email server (which may or may not work depending upon your upstream provider) as well as an SMTP relay host such as Gmail. You'll find it under Admin -> System Settings. In the alternative, you may prefer to do it yourself. Here's how.

1. Log into your server as root and issue the following command:

dpkg-reconfigure postfix

Click OK on the first dialog. Choose Internet Site as your Type of Mail Configuration. Accept the defaults for the System Mail Name, Root and Postmaster Recipient, and Other Destinations. Choose Yes for Forced Synchronous updates. Accept the defaults for the Local Networks, Default Mailbox Size, and Local Address Extension Character. Choose IPv4 for the Internet Protocol.

2. Once Postfix is reconfigured, edit /etc/postfix/main.cf. In the second section of code beginning with relayhost =, replace the relayhost= line with the following block of commands:

relayhost = [smtp.gmail.com]:587
smtp_use_tls = yes
smtp_sasl_auth_enable = yes
smtp_sasl_security_options = noanonymous
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_tls_CAfile = /etc/ssl/certs/ca-certificates.crt
smtp_fallback_relay =

3. Create the following new file using your Gmail account name and password.

nano -w /etc/postfix/sasl_passwd:

[smtp.gmail.com]:587 yourname@gmail.com:yourpassword

5. Change the permissions on the sasl_passwd file:

chmod 600 /etc/postfix/sasl_passwd

6. Use postmap to compile and hash the sasl_passwd file:

postmap /etc/postfix/sasl_passwd

7. Restart Postfix: systemctl restart postfix

8. apt -y install mailutils

9. Send yourself a test email: echo "test" | mail -s "Test Mail" somebody@gmail.com

Free Voicemail Transcription of Messages

For many years, Incredible PBX has included documentation to deploy IBM's Speech-to-Text (STT) engine to transcribe voicemail messages and deliver them by email for missed calls. Today we are pleased to bring that same functionality to VitalPBX 4. To get started, make certain that you have outbound email functioning on your server using the steps in the previous section. Then open an account with IBM and sign up for their LITE Speech-to-Text service. This provides you with 500 minutes a month of free STT transcription; however, you must use it at least once every 30 days or risk having your STT account terminated. So you may wish to setup up a recurring weekly reminder at a time when your extension will not otherwise be answered. Set up a short message to assure that voicemail transcription will be triggered. This will keep your LITE plan active without using many of your allocated minutes.

Once you have signed up for the STT-LITE service, navigate to Resources:AI/Machine Learning:STT in the LITE Tier and obtain or create an API Key and URL. Copy both the API Key and URL to your desktop. You'll need them as part of the VitalPBX component install below.


Next, login to your VitalPBX server as root and issue the following commands:

cd /root
apt -y install dos2unix lame
wget https://filedn.com/lBgbGypMOdDm8PWOoOiBR7j/VitalPBX-4/sendmailibm.tar.gz
tar zxvf sendmailibm.tar.gz
rm -f sendmailibm.tar.gz
nano -w sendmailibm
# insert your API Key and URL and Save file: Ctrl-X, Y, ENTER
cp -p sendmailibm /usr/local/sbin/.
cp -p voicemail__60-1-transcript.conf /etc/asterisk/vitalpbx/.
asterisk -rx "dialplan reload"

When the nano editor opens in step 6 above, insert your API Key and URL in the spaces provided. Then save the file: Ctrl-X, Y, then ENTER. Continue with the remaining steps above to complete the install.

By default, this setup assumes that incoming calls are delivered to an extension on your PBX. Assuming that is extension 501, open the VitalPBX GUI and edit your Extension's settings by adding your email address in General Settings and in the Voicemail tab specify Enable Voicemail and Attach Voicemail YES. If you wish to delete the messages from your server after sending the email, specify Delete YES. Then save your settings and reload your dialplan.


Finally, make a test call to that extension and don't answer. Leave a brief message and hang up. The transcribed voicemail together with an MP3 recording of the message should arrive within a minute or two.

You Snooze, You Lose

Sorry to say our supply of free licenses to one of our favorite add-ons, the $100 Starter Kit, has been exhausted. If we get additional ones to hand out, we'll post an update here. Here's what's included in the VitalPBX Starter Kit:


Originally published: Monday, August 7, 2023    Updated: September 13, 2023



Need help with Asterisk? Visit the VoIP-info Forum.


 

Special Thanks to Our Generous Sponsors


FULL DISCLOSURE: ClearlyIP, Skyetel, Vitelity, DigitalOcean, Vultr, VoIP.ms, 3CX, Sangoma, TelecomsXchange and VitalPBX have provided financial support to Nerd Vittles and our open source projects through advertising, referral revenue, and/or merchandise. As an Amazon Associate and Best Buy Affiliate, we also earn from qualifying purchases. We’ve chosen these providers not the other way around. Our decisions are based upon their corporate reputation and the quality of their offerings and pricing. Our recommendations regarding technology are reached without regard to financial compensation except in situations in which comparable products at comparable pricing are available from multiple sources. In this limited case, we support our sponsors because our sponsors support us.

BOGO Bonaza: Enjoy state-of-the-art VoIP service with a $10 credit and half-price SIP service on up to $500 of Skyetel trunking with free number porting when you fund your Skyetel account. No limits on number of simultaneous calls. Quadruple data center redundancy. $25 monthly minimum spend required. Tutorial and sign up details are here.

The lynchpin of Incredible PBX 2020 and beyond is ClearlyIP components which bring management of FreePBX modules and SIP phone integration to a level never before available with any other Asterisk distribution. And now you can configure and reconfigure your new Incredible PBX phones from the convenience of the Incredible PBX GUI.

VitalPBX is perhaps the fastest-growing PBX offering based upon Asterisk with an installed presence in more than 100 countries worldwide. VitalPBX has generously provided a customized White Label version of Incredible PBX tailored for use with all Incredible PBX and VitalPBX custom applications. Follow this link for a free test drive!
 

Special Thanks to Vitelity. Vitelity is now Voyant Communications and has halted new registrations for the time being. Our special thanks to Vitelity for their unwavering financial support over many years and to the many Nerd Vittles readers who continue to enjoy the benefits of their service offerings. We will keep everyone posted on further developments.
 



Summer Break: Catching Up on Nerd Vittles Happenings



Nerd Vittles has been churning out technology articles for well over a decade. And, while you’re enjoying your time off this summer, we thought you might enjoy catching up on some of our most-read articles. According to Google Analytics, these were the most recent top picks from the 1.2+ million visitors who have dropped in to Nerd Vittles these past 10 years.
 

Our Favorite All-You-Can-Eat Deals in Cyberspace is self-explanatory covering a free cloud offering, domains at cost, VPN offerings for life, unlimited music streaming services, unlimited home internet service, lifetime cloud storage services, lifetime email hosting together with a few services to avoid.

Incredible PBX 2027-U for Proxmox 7 will walk you through setting up a Proxmox server and building Incredible PBX 2027 virtual machines with Ubuntu® 22.04, Asterisk® 20, and FreePBX® 16 in minutes using a powerful little MiniPC.

The 5-Minute PBX in the Cloud Platform for $2 a Month introduces the same Incredible PBX 2027-U platform from one of our favorite cloud services, CrownCloud. It’s $25 a year and includes a free backup image with your choice of locations: Los Angeles, Atlanta, Miami, Germany, or The Netherlands.

gTTS: The Ultimate (free) Text-to-Speech Engine for Asterisk introduces our favorite text-to-speech engine for Asterisk which also happens to be free. It’s now included with all Incredible PBX 2027 platforms.

For those that prefer to build your own server platforms, we’ve introduced Incredible PBX install scripts and tutorials for the following operating systems:

$1 a Month Buys a Cloud Powerhouse for Incredible PBX, an alternative for those that find $2 a month cost prohibitive for cloud hosting. You get an equally powerful platform from RackNerd but no backup option is included. Installation of Incredible PBX is a two-step process: installing an operating system image and then running the matching Incredible PBX 2027 installer.

$0 a Month Buys an Oracle Cloud Powerhouse, an alternative that’s free if you’re lucky enough to snag an instance.

Finally, a few of our favorite SIP providers with our reasons why:

  • Skyetel – Half-price calls with your first $250 purchase. $25/mo. minimum spend.
  • Clearly Anywhere – The ultimate mobile user VoIP companion
  • Linphone – Free SIP Calling to Anybody, Anywhere
  • CallCentric – $1 a month residential DID with free incoming SIP calls
  • FreeVoipDeal – €10.00 for 300 min./week of free calls to 33 countries for 120 days

Enjoy your summer break!

Originally published: Monday, July 24, 2023



Need help with Asterisk? Visit the VoIP-info Forum.


 

Special Thanks to Our Generous Sponsors


FULL DISCLOSURE: ClearlyIP, Skyetel, Vitelity, DigitalOcean, Vultr, VoIP.ms, 3CX, Sangoma, TelecomsXchange and VitalPBX have provided financial support to Nerd Vittles and our open source projects through advertising, referral revenue, and/or merchandise. As an Amazon Associate and Best Buy Affiliate, we also earn from qualifying purchases. We’ve chosen these providers not the other way around. Our decisions are based upon their corporate reputation and the quality of their offerings and pricing. Our recommendations regarding technology are reached without regard to financial compensation except in situations in which comparable products at comparable pricing are available from multiple sources. In this limited case, we support our sponsors because our sponsors support us.

BOGO Bonaza: Enjoy state-of-the-art VoIP service with a $10 credit and half-price SIP service on up to $500 of Skyetel trunking with free number porting when you fund your Skyetel account. No limits on number of simultaneous calls. Quadruple data center redundancy. $25 monthly minimum spend required. Tutorial and sign up details are here.

The lynchpin of Incredible PBX 2020 and beyond is ClearlyIP components which bring management of FreePBX modules and SIP phone integration to a level never before available with any other Asterisk distribution. And now you can configure and reconfigure your new Incredible PBX phones from the convenience of the Incredible PBX GUI.

VitalPBX is perhaps the fastest-growing PBX offering based upon Asterisk with an installed presence in more than 100 countries worldwide. VitalPBX has generously provided a customized White Label version of Incredible PBX tailored for use with all Incredible PBX and VitalPBX custom applications. Follow this link for a free test drive!
 

Special Thanks to Vitelity. Vitelity is now Voyant Communications and has halted new registrations for the time being. Our special thanks to Vitelity for their unwavering financial support over many years and to the many Nerd Vittles readers who continue to enjoy the benefits of their service offerings. We will keep everyone posted on further developments.