[Asterisk-Users] Reverse phone lookup interface with asterisk (2024)

All hail rentacoder.com - a few bucks poorer I have a perfectly usable
script for reverse phone lookups. I send a jabber message to myself for
every incoming call including data from this reverse phone lookup perl
script.

There's probably a smarter way to post this, let me know and I'll comply.

---------------------

#Script to reverse lookup information
#in http://anywho.com database
#Usage: rl telephone# in format like: 1234567890

#hidden par c
#npa
#telephone
$base_url = 'http://anywho.com/qry/wp_rl';
$get_c_url = 'http://anywho.com/qry/getc.pl';

$timeout = 20;

$referer = '"http://anywho.com/qry/wp_rl"';
$user_agent = '"Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.5)
Gecko/20041107 Firefox/1.0"';
$curl = "curl -s -m $timeout -e $referer -A $user_agent ";

if($#ARGV+1 == 1)
{
$phone = $ARGV[0];

$cmd = "$curl $get_c_url";
#print "Executing : $cmd\n";
$c = `$cmd`;
$ret = $? >> 8;
if(!$ret)
{
@cvals = $c =~ /value\s=\s"([^"]*?)"/s;
$c = $cvals[0];
#print "Got C value : $c\n";

$npa = substr($phone, 0, 3);
$num = substr($phone, 3);
$xy = 'btnsubmit.x=37&btnsubmit.y=8';

$cmd = "$curl -d \"c=$c&npa=$npa&telephone=$num&$xy\" $base_url";

#print "Getting from: $cmd\n";

$data = `$cmd`;
$ret = $? >> 8;
if(!$ret)
{
#print "$data\n";

#@values = $data =~
/<!--\slisting.*?<B>([^<]+?)<.*?-->\s*([^<]+?)<.*?>\s*([^<]+?)</si;
@values = $data =~
/<!--\slisting.*?<B>([^<]+?)<.*?-->(.*?)<\/div/si;
if($#values > -1)
{
($surename, $name) = split(/, /, $values[0], 2);
$data = $values[1];
$data =~ s/\s+/ /gs;
@vals2 = $data =~ /\s*(.*?)<BR>/sgi;
if($#vals2 == 1)
{
$address = $vals2[0];
($city, $statezip) = split(/, /, $vals2[1], 2);
print(($name ? $name.', ' : '')."$surename, $address,
$city, $statezip\n");
}
else
{
($city, $statezip) = split(/, /, $vals2[0], 2);
print(($name ? $name.', ' : '')."$surename, $city,
$statezip\n");
}
}
else
{
print "Nothing found?\n";
}
}
else
{
print "$ret\n";
}
}
else
{
print "$c\n";
}
}
else
{
print "Usage rl phone#\n";
}

---------------------

-----Original Message-----
Sent: Tuesday, February 01, 2005 2:52 AM
To: 'Asterisk Users Mailing List - Non-Commercial Discussion'
Subject: RE: [Asterisk-Users] Reverse phone lookup interface with asterisk
Yep -- 'xept that side simply refers you to 411.com, phonenumber.com and
whitepages.com, which are all three different flavors of the same site
-- data returned is identical. In comparison, this data seems more
complete and up-to-date than anywho.com or switchboard (which in turn
seem identical as well). Can it be that there really only are two
different sources of phonebook data online?

-----Original Message-----
Sent: Tuesday, February 01, 2005 12:31 AM
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [Asterisk-Users] Reverse phone lookup interface
with asterisk
use
http://www.reversephonedirectory.com/
it works for business as well as residential, I have been
using it for years.

Post by Jay Milk
I got mine done last weekend, using 411.com for lookups and

mysql to

Post by Jay Milk
customize it. I'll post it when I have a chance. If you plan on
using it, have PHP5 and mySQL ready on your server.

-----Original Message-----
Sent: Monday, January 31, 2005 4:28 PM
To: 'Asterisk Users Mailing List - Non-Commercial Discussion'
Subject: RE: [Asterisk-Users] Reverse phone lookup interface with
asterisk
Just thought I'd post an update on my progress.
- I asked ServiceObjects to create a Perl script - no

response yet.

Post by Jay Milk

http://search.cpan.org/~phocus/revphone-0.01/lib/revphone.pm.
Managed to integrate it with my email and jabber notification
scripts without too much hassle. Seems to work well, but for
residential listings only - doesn't work for businesses.
Missing business listings is not good - I'm going to keep looking
for pay-for and free solutions.
Thanks - Joe

-----Original Message-----

[mailto:asterisk-users-

Sent: Tuesday, January 18, 2005 8:46 PM
Subject: [Asterisk-Users] Reverse phone lookup interface with
asterisk
I've had some success setting up a crude "screen pops"

using Jabber,

Post by Jay Milk

and am pretty happy with it. But I'd love to have it pop

up with the

Post by Jay Milk

full name and address of the caller.
The easiest way to do this is using ServiceObjects "GeoPhone" web
service
-
although it's expensive for small shops (free trial, but $50+/mo
after that). The interface would be pretty simple using Perl and

SOAP::Lite, if

one knew Perl. Which, after a few hours of tinkering, I

can safely

Post by Jay Milk
say I

don't.
Has anyone written an interface to this by any chance?
Or even better -
Has anyone written an interface to Google's search, which

appears to

Post by Jay Milk

have free reverse # lookup?
Thanks - joe

_______________________________________________
Asterisk-Users mailing list
http://lists.digium.com/mailman/listinfo/asterisk-users
http://lists.digium.com/mailman/listinfo/asterisk-users
_______________________________________________
Asterisk-Users mailing list
http://lists.digium.com/mailman/listinfo/asterisk-users
http://lists.digium.com/mailman/listinfo/asterisk-users

--
Dr. Matthew Roller
9355 S 1300 E
Sandy, UT 84094
801-255-3925
http://www.rollerchiropractic.com
_______________________________________________
Asterisk-Users mailing list
http://lists.digium.com/mailman/listinfo/aster> isk-users
To

http://lists.digium.com/mailman/listinfo/asterisk-users
_______________________________________________
Asterisk-Users mailing list
http://lists.digium.com/mailman/listinfo/asterisk-users
http://lists.digium.com/mailman/listinfo/asterisk-users

[Asterisk-Users] Reverse phone lookup interface with asterisk (2024)

FAQs

What does asterisk mean on phone? ›

In conjunction with suitable telephony hardware interfaces and network applications, Asterisk is used to establish and control telephone calls between telecommunication endpoints such as customary telephone sets, destinations on the public switched telephone network (PSTN) and devices or services on voice over Internet ...

How does reverse number lookup work? ›

Reverse phone lookup works by using a database of phone numbers and their associated information to find details about a specific number. The user enters the phone number into the tool, and the tool searches the database to provide results.

Who uses asterisk? ›

Asterisk powers IP PBX systems, VoIP gateways, conference servers, and is used by SMBs, enterprises, call centers, carriers and governments worldwide.

What is the asterisk commonly used for? ›

Its most common use is to call out a footnote. It is also often used to censor offensive words. In computer science, the asterisk is commonly used as a wildcard character, or to denote pointers, repetition, or multiplication.

What does an asterisk(*) indicate? ›

An asterisk is a star-shaped symbol (*) that has a few uses in writing. It is most commonly used to signal a footnote, but it is sometimes also used to clarify a statement or to censor inappropriate language.

What is the * key used for on a phone? ›

In our phone system, the * key is used to access the menus that allow the user to set up their voice mail, greetings, and other options. For a “home phone” that does not have those options, there * key is unlikely to ever be used for anything. (Same with the # key.)

What is the star symbol on my Android phone? ›

If the interrupt mode is activated as "Priority" , the star icon in the status bar of your Android smartphone Lollipop appears. "Priority" in the "Interruptions Mode" means that only calls and notifications appear , which you have previously considered as important.

What does an asterisk mean in a text? ›

An asterisk is the sign *. It is used especially to indicate that there is further information about something in another part of the text. A single sentence, marked with an asterisk.

Top Articles
Latest Posts
Article information

Author: Arline Emard IV

Last Updated:

Views: 6005

Rating: 4.1 / 5 (52 voted)

Reviews: 83% of readers found this page helpful

Author information

Name: Arline Emard IV

Birthday: 1996-07-10

Address: 8912 Hintz Shore, West Louie, AZ 69363-0747

Phone: +13454700762376

Job: Administration Technician

Hobby: Paintball, Horseback riding, Cycling, Running, Macrame, Playing musical instruments, Soapmaking

Introduction: My name is Arline Emard IV, I am a cheerful, gorgeous, colorful, joyous, excited, super, inquisitive person who loves writing and wants to share my knowledge and understanding with you.