Ultimate CNAM Lookup

Titanous

New Member
Joined
Oct 18, 2007
Messages
164
Reaction score
0
***THIS SCRIPT IS NO LONGER SUPPORTED***

I really needed a faster CallerID Name lookup script, so I wrote one. It includes Canadian and US lookups, spam lookup, and if it cannot find a name, it will include the rate center of the number (City/Province). Most queries are executed within 2 seconds.

Get the install instructions here:
Ultimate CNAM User Guide
Please note that the install script will not work with Trixbox. Please do not contact me asking how to get it to work on TB. The script only supports PBX-in-a-Flash!

To upgrade to v1.2, just rerun the install script.

Features
Code:
Supports 8 lookup providers:
  Asteridex
  WhoCalled.Us (registration required)
  Whitepages.com
  AnyWho.com
  Canada411.com
  Google Phonebook
  TelcoData (Ratecenter)
  Fonetastic (Ratecenter)


Changelog

Code:
11/13/07  [URL="http://titanous.com/asterisk/cnam/cnam-0.5.pl"]v0.5[/URL]    - Initial Public Release
11/14/07  [URL="http://titanous.com/asterisk/cnam/cnam-0.6.pl"]v0.6[/URL]    - Updated scraping algorithms, and added name reversal feature
11/26/07  [URL="http://titanous.com/asterisk/cnam/cnam-0.6.1.pl"]v0.6.1[/URL]  - Removed toll free NPAs
12/01/07  [URL="http://titanous.com/asterisk/cnam/cnam-0.7.pl"]v0.7[/URL]    - Code cleanup and WhoCalled.Us support added
01/03/08  [URL="http://titanous.com/asterisk/cnam/cnam-1.0.pl"]v1.0[/URL]    - More code cleanup, Asteridex support, [URL="http://titanous.com/asterisk/cnam/cnam-config.pl"]config system[/URL], scraping rewrite, and more!
06/04/08  [URL="http://titanous.com/asterisk/cnam/cnam-1.1.pl"]v1.1[/URL]    - Fixed Whitepages scraping issues
06/11/08  [URL="http://titanous.com/asterisk/cnam/cnam.pl"]v1.2[/URL]    - Abstracted printing, removed Content-type for debug


Thanks to Tom for the install script!

Disclaimer

Please note this script may violate the terms of service of some of the sites. It is up to you to ensure you have met all the legal requirements and any terms the providers may have. By using this script you agree you that the author, PBX in a Flash, and any of it's developers shall not be held liable for the use of the script.
 

telemach

New Member
Joined
Oct 21, 2007
Messages
36
Reaction score
0
btw : have you seen this one ?

http://www.oldskoolphreak.com/tfiles/voip/supercallerid.txt

callerid_screen1.jpg
 

Titanous

New Member
Joined
Oct 18, 2007
Messages
164
Reaction score
0
I have seen that and it is a very good start. Eventually I hope to put together a web page using AJAX that does that and some other things including Google maps.
 

Titanous

New Member
Joined
Oct 18, 2007
Messages
164
Reaction score
0
Install instructions are up! (See first post)

Please post any bugs/feature requests.
 

Titanous

New Member
Joined
Oct 18, 2007
Messages
164
Reaction score
0
Fixed an error in the install instructions. Thanks to w1ve for the report.

If you were having issues installing the RPMs, the instructions should work now.
 

Titanous

New Member
Joined
Oct 18, 2007
Messages
164
Reaction score
0
Maybe a mod could move this to Add-On Install Instructions?

EDIT: Thanks!
 

Titanous

New Member
Joined
Oct 18, 2007
Messages
164
Reaction score
0
I've got someone who is having a issue with this script. When a incoming call comes with the script enabled, it sends it directly to VM. When it is disabled, the call is routed correctly. Has anyone else tested the script? I have tested it, but only on two machines.

Please post your feedback!

Thanks!
 

Vik

New Member
Joined
Nov 14, 2007
Messages
25
Reaction score
0
Installed your script yesterday. No problems here, works perfectly
 

Tdar

New Member
Joined
Nov 21, 2007
Messages
4
Reaction score
0
I'm running the script on a PBX in a Flash system with out any major issues. I can't get Asteridex to work ( I know you're not supporting it yet) but that might not be a problem with the script....It's not working with any other scripts on this install ...I liked your path here....I'm waiting for Ward and company to do the next version before I worry about this.

I also can't get debug mode to work. The debug data never shows up in the console even under verbose mode. No big deal but it would be nice to have this working.

Other than these two things it works great.....Thanks for your work on it, I was struggling to find a good CNAME utility for the PIAF untill I found yours....
 

Titanous

New Member
Joined
Oct 18, 2007
Messages
164
Reaction score
0
Thanks for the feedback!

As far as debug data goes, to run it from the command line you need to execute it like this:
Code:
REQUEST_METHOD=GET QUERY_STRING='number=1235557654' /var/www/perl/cnam.pl
 

Tdar

New Member
Joined
Nov 21, 2007
Messages
4
Reaction score
0
Thanks for the feedback!

As far as debug data goes, to run it from the command line you need to execute it like this:
Code:
REQUEST_METHOD=GET QUERY_STRING='number=1235557654' /var/www/perl/cnam.pl

Got it ...Thanks!
 

clarocque

New Member
Joined
Nov 17, 2007
Messages
44
Reaction score
0
Wow this went in very easy and worked right off.

I left the services set as the default, but I am curious... why all the different ones and why use all or some or more than one?

Thanks,

Chris
 

Titanous

New Member
Joined
Oct 18, 2007
Messages
164
Reaction score
0
why all the different ones and why use all or some or more than one?

Some services provide business lookups, and some don't. Some may not have the result you are looking for. Some may be slower than others. If one site goes down or blocks the script you can still use the others.

There are quite a few reasons, but the default options have the best results in my case.
 

clarocque

New Member
Joined
Nov 17, 2007
Messages
44
Reaction score
0
Thanks for the info. So does it go through the list top to bottom until it finds a match? I am really sorry for my very limited knowledge.. I am just trying to get a little understanding.

Thanks
 

edmondt

New Member
Joined
Nov 22, 2007
Messages
2
Reaction score
0
*Edit I found the solution, I have a fresh install and I need to goto Module Administration | Check for updates online... and install the caller id lookup module.

FreePBX -> CallerID Lookup Sources:

Source Description: Ultimate CNAM
Source Type: HTTP
Cache Results: Yes
Host: 127.0.0.1
Path: /perl/cnam.pl
Query: number=[NUMBER]



Enable it in your Inbound Routes

...Where would I find the option: CallerID Lookup Sources in FreePBX?
 

klingon888

Guru
Joined
Nov 23, 2007
Messages
90
Reaction score
4
I went to the /etc/httpd/conf.d/ directory and cannot find the file perl.conf. Mine is a TB install from fresh. Tried adding this file manually but when I restart httpd, it failed. Thx.



Uncomment these lines in /etc/httpd/conf.d/perl.conf


Code:
Alias /perl /var/www/perl
<Directory /var/www/perl>
SetHandler perl-script
PerlResponseHandler ModPerl::Registry
PerlOptions +ParseHeaders
Options +ExecCGI
</Directory>
 

klingon888

Guru
Joined
Nov 23, 2007
Messages
90
Reaction score
4
Bug when looking up toll-free??

Ignore previous post. Found out I need to yum install mod_perl first.

Anyway, it works great but when I tried your debug statement for toll-free numbers, I get the following msg. Is this an error? Tried other toll-free numbers and still same msg.

REQUEST_METHOD=GET QUERY_STRING='number=8882173840' /var/www/perl/cnam.pl
Content-type: text/html

Checking 888 217 3840...
Asteridex lookup disabled.
Valid NPA
Ready for Whitepages lookup...
&_RM_HTML_XF_ESC_= &_RM_HTML_XL_ESC_=&_RM_HTML_HOUSE_ESC_=&_RM_HTML_XHN_ESC_=&_RM_HTML_STREET_ESC_=&_RM_HTML_XST_ESC_=&_RM_HTML_CITY_ESC_=&_RM_HTML_XC_ESC_=&_RM_HTML_STATE_ESC_=&_RM_HTML_XS_ESC_=&_RM_HTML_ZIP_ESC_=&_RM_HTML_XZ_ESC_=
Whitepages match. New CallerIDName = &_RM_HTML_XF_ESC_= &_RM_HTML_XL_ESC_=&_RM_HTML_HOUSE_ESC_=&_RM_HTML_XHN_ESC_=&_RM_HTML_STREET_ESC_=&_RM_HTML_XST_ESC_=&_RM_HTML_CITY_ESC_=&_RM_HTML_XC_ESC_=&_RM_HTML_STATE_ESC_=&_RM_HTML_XS_ESC_=&_RM_HTML_ZIP_ESC_=&_RM_HTML_XZ_ESC_=
 

Titanous

New Member
Joined
Oct 18, 2007
Messages
164
Reaction score
0
It looks like a bug. I'll have to take a look when I get back to my main computer.
 

Members online

Forum statistics

Threads
25,802
Messages
167,720
Members
19,232
Latest member
voiplads
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