CallerID Creep Detector -- record name solution

zipeee

Member
Joined
Jun 15, 2009
Messages
85
Reaction score
0
Hi,

A while ago, I was using TB 2.0/asterisk 1.2 and used Klingon 888's script that screens anonymous/unknown/private calls that was put in the extensions_custom.conf. Anyways, when I upgraded to PBIAF 1.4 and Asterisk 1.6, this broke. I noticed that FreePBX has a call screening option, but this only works on a per extension basis.

The original script I had screens all inbound calls for the anonymous/out of area/private/unknown. If it has a normal caller ID, it sends it on to whatever ringgroup/IVR you want, but if it is one of these unknown calls, it filters it and asks the creep to record his or her name, rings the various extensions, and they go through the "so and so is calling, press 1 to accept, 2 to send to voicemail, 3 to send to the torture menus, 4 to send a polite do not call). Just like Verizon's Call Intercept / AT&T's Privacy Manager/Director work.

Free PBX's Call screening is the same thing, but works on an extension basis only and it doesn't filter the call based on whether it is unknown or not. In a household, where you want to screen anonymous calls only and force them to record their name first and ring a batch of extensions together, I found a way to force the call to go through the process and then go to a custom extension that acts as the call intercept extension.


For this to work:

1. Create a custom extension called "filter" (or whatever you want) I use extension 95. In this extension, you want it to forward to the filtering script in step 2 below. To do this, in the "This device uses custom technology" "dial" option, put in Local/s@from-external-custom" This will force all calls routed into this extension to go through the "determine if the call is anonymous/out of area/unknown" script below. Also, you will want to set your inbound calls to land all inbound calls into this extension.


2. Add the following script filtering for unknown calls to extensions_custom.conf

[from-external-custom]
exten => s,1,Zapateller(answer|nocallerid)
exten => s,2,Wait(1)
exten => s,3,SetMusicOnHold(default)
exten => s,4,GotoIf($["${CALLERID(num)}" = ""]?custom-screen,s,1)
exten => s,5,GotoIf($["foo${CALLERID(num)}" = "foo"]?custom-screen,s,1)
exten => s,6,GotoIf($["${CALLERID(name):0:9}" = "Anonymous"]?custom-screen,s,1)
exten => s,7,GotoIf($["${CALLERID(name):0:7}" = "Unknown"]?custom-screen,s,1)
exten => s,8,GotoIf($["${CALLERID(num):0:7}" = "Private"]?custom-screen,s,1)
exten => s,9,GotoIf($["${CALLERID(name):0:7}" = "Private"]?custom-screen,s,1)
exten => s,10,GotoIf($["${CALLERID(num):0:10}" = "Restricted"]?custom-screen,s,1)
exten => s,11,GotoIf($["${CALLERID(num):0:4}" = "PSTN"]?custom-screen,s,1)
exten => s,12,Dial(Local/1200@from-internal)
exten => s,13,Hangup

[custom-screen]
exten => s,1,Background(privacy-unident)
exten => s,2,Dial(Local/599@from-internal) ;replace with your follow-me..call screening enabled extension
exten => s,3,Hangup

This script plays the zapateller to all anonymous calls (change the | to a , in asterisk 1.6) and if they are normal numbers they go to the destination 1200 (misc. app that points to my regular welcome IVR). If they are anonymous, it plays "the party doesn't accept unidentifed calls" and sends it to extension 599 (my call intercept extension below)

3. Create a "call intercept" extension. In this case, I use 599. I turn on Call Screening-> Screen Call: No memory option on in this extension (on my FreePBX 2.5.1.5).
Normally, only this extension would ring, but I force all the extensions in the house to ring (step 4).

4. In the "dial" field for this extension under "this device uses sip or custom technology" I put my ring group 602, which looks like "local/602@from-internal" so it causes all phones in this ring group to ring, and not just extension 599 only. (FreePBX's default behavior doesn't let call screening work with ring groups--they claim it works with follow-me, but I couldn't get it to work, it would just hang up)

5. The anonymous caller will be asked by the freepbx call screener to record their name, and the extensions in the ring group (602 in my case) will ring. You would need a voice mailbox on extension 599 for all anonymous voicemails left if you choose option 2--send to voicemail

6. Optional: I didn't like the polite and torture menu options. I changed the torture "music on hold" to play a recording "telehold" hold message that I got (funny, on hold message, I got it off of youtube -- that i converted to .ulaw and put in my /var/lib/asterisk/sounds folder. [http://www.youtube.com/watch?v=8-yU5Ekv14U]).

I changed the polite hold message as well to the allison "if this is a telemarketing sales...we only wish to be contacted in writing. If you want to make these optional modifications, they are in the ;call screening section of the free pbx extensions.conf. Mine looks like:

; For call screening
exten=>NOANSWER,1,Macro(vm,${SCREEN_EXTEN},BUSY,${IVR_RETVM})
exten => NOANSWER,n,GotoIf($["${IVR_RETVM}" != "RETURN" | "${IVR_CONTEXT}" = ""$
exten => NOANSWER,n,Return
exten => NOANSWER,n(bye),Macro(hangupcall)
exten => TORTURE,1,Playback(telehold)
;exten => TORTURE,1,Goto(app-blackhole,musiconhold,1)
exten => TORTURE,n,Macro(hangupcall)
exten => DONTCALL,1,Answer
exten => DONTCALL,n,Wait(1)
exten => DONTCALL,n,Zapateller()
exten =>DONTCALL,n,Playback(privacy-if-sales-call-contact-in-writing)
exten => DONTCALL,n,Macro(hangupcall)
 

zipeee

Member
Joined
Jun 15, 2009
Messages
85
Reaction score
0
cellphone option

Just a little call manager I found for my cellphone:

http://www.webgate.bg/products/acm/

On symbian (and maybe some others), this call manager can be set to automatically forward private/anonymous/unknown callers to another number.

I have it set to forward these calls to my asterisk box which then forces them to record their name.
 

Members online

Forum statistics

Threads
25,838
Messages
167,923
Members
19,259
Latest member
dancosge
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top