Detect difference between private and unknown number

Hi,
Can I configure Asterisk to handle “unknown” numbers differently from “private” numbers? Even though I’m on the Do Not Call list I seem to, for some reason, be receiving a lot of marketing calls from numbers that appear on my actual phones as “Unknown Name/Unknown Number”. I do receive some legitimate calls from “Private Number” or “Blocked Caller” and additionally none of the marketing calls come from blocked numbers. I setup an extension match in my dialplan to send any call where the CALLERID(num) variable is blank to a brief message along with Zapateller() however this also is sending people who call with blocked numbers to the rejection extension. I want to allow calls that are private through but not calls that are “unknown”. Can Asterisk do this? If my cheap $15 phone can tell the diff, surely Asterisk can?..

Flint M

to write a custom context for my inbound DID and have it (a php/agi script) parse the callerid number and name and if it was absent or one of a set of bogus strings i always see, to invoke zapateller and privacy manager, and if it passes all of that, it jumps back into the regular flow. this is using freepbx as the gui so hooking into the call flow was easy.

I could use AGI, is there a way to get AGI to see the literal raw CID data? The CALLERID(all) variable ALWAYS shows “” <> for both private and unknown numbers. Need to distinguish between the two…
Flint

sounds like you are not getting correct CID info from your provider. when i called my voip line from my cellphone with CID blocked, it looks like this:

“Anonymous”

could it have something to do with my Zap drivers? as I said my normal PSTN phone which bypasses asterisk completely and receives the CID itself can tell the difference. It displays “blocked call” for numbers blocked with *67 and “unknown name” for telemarketers deliberately blocking their info.

i don’t have any zap devices, and it’s been awhile, so i can’t make any suggestions on how to setup and troubleshoot CID for zap…

bump… anyone else? ZAP CID help…