AsteriskNow: Block Incoming Numbers By Area Code 1

I use AsteriskNow for my work phone system.  One annoyance I ran into was repeated fax spam.  I don’t use the fax features on AsterskNow, but every time my voicemail picked up a call from these numbers, I would receive a voicemail full of fax beeps.  I started adding the numbers to my blacklist, but each time it seemed to be a different number.  As the list grew, I noticed a pattern: all the fax spam calls were coming from the same area code and three-digit prefix from Alberta, Canada.  Here’s what I did to block all calls from this area code and three-digit prefix (i.e. all numbers starting with the same six digits.

Create an Inbound route that matches any DID (destination number) and use an Asterisk pattern to match multiple CIDs (calling numbers).  In the example pictured, this incoming route will match any call to any destination FROM a number that starts with 555555.  Checking the CID Priority Route box makes sure that this route will override any other incoming route you might have (i.e. one that might match by DID).

Inbound Route Matching Multiple CIDs

Inbound Route Matching Multiple CIDs

Set the destination to terminate with Play SIT Tone (Zapateller).  This will play the Intercept Special Information Tone and then hang up.

Destination: Play SIT Tone and Terminate Call

Destination: Play SIT Tone and Terminate Call

You can test this incoming route by putting the first six digits of your cell number into the CID matching pattern and then calling your system from your cell phone.

 

 

One comment on “AsteriskNow: Block Incoming Numbers By Area Code

Leave a Reply