Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Perl > Perl Misc > reverse dns

Reply
Thread Tools

reverse dns

 
 
sihyung@gmail.com
Guest
Posts: n/a
 
      08-18-2006
Does anybody know how to perform a reverse dns that returns the number
of domains associated with a certain IP? Thanks

 
Reply With Quote
 
 
 
 
axel@white-eagle.invalid.uk
Guest
Posts: n/a
 
      08-18-2006
http://www.velocityreviews.com/forums/(E-Mail Removed) wrote:
> Does anybody know how to perform a reverse dns that returns the number
> of domains associated with a certain IP? Thanks


No.

DNS does not work that way... hint... domains do not have IP numbers.

Now go away unless you have a something Perl related to say.

Axel

 
Reply With Quote
 
 
 
 
John Bokma
Guest
Posts: n/a
 
      08-18-2006
(E-Mail Removed) wrote:

> (E-Mail Removed) wrote:
>> Does anybody know how to perform a reverse dns that returns the number
>> of domains associated with a certain IP? Thanks

>
> No.
>
> DNS does not work that way... hint... domains do not have IP numbers.


What the OP means (guess) is that for a given IP address he wants to
get a list of all domains that are hosted on that address.

The Perl question could be, which CPAN module can be used to accomplish
this. Net:NS maybe?


--
John Experienced Perl programmer: http://castleamber.com/

Perl help, tutorials, and examples: http://johnbokma.com/perl/
 
Reply With Quote
 
Uri Guttman
Guest
Posts: n/a
 
      08-18-2006
>>>>> "JB" == John Bokma <(E-Mail Removed)> writes:

JB> (E-Mail Removed) wrote:
>> (E-Mail Removed) wrote:
>>> Does anybody know how to perform a reverse dns that returns the number
>>> of domains associated with a certain IP? Thanks

>>
>> No.
>>
>> DNS does not work that way... hint... domains do not have IP numbers.


JB> What the OP means (guess) is that for a given IP address he wants to
JB> get a list of all domains that are hosted on that address.

JB> The Perl question could be, which CPAN module can be used to accomplish

why even use a module? the getXXbyXX functions support basic reverse dns
lookups.

uri

--
Uri Guttman ------ (E-Mail Removed) -------- http://www.stemsystems.com
--Perl Consulting, Stem Development, Systems Architecture, Design and Coding-
Search or Offer Perl Jobs ---------------------------- http://jobs.perl.org
 
Reply With Quote
 
John Bokma
Guest
Posts: n/a
 
      08-18-2006
Uri Guttman <(E-Mail Removed)> wrote:

>>>>>> "JB" == John Bokma <(E-Mail Removed)> writes:

>
> JB> (E-Mail Removed) wrote:
> >> (E-Mail Removed) wrote:
> >>> Does anybody know how to perform a reverse dns that returns the
> >>> number of domains associated with a certain IP? Thanks
> >>
> >> No.
> >>
> >> DNS does not work that way... hint... domains do not have IP
> >> numbers.

>
> JB> What the OP means (guess) is that for a given IP address he
> wants to JB> get a list of all domains that are hosted on that
> address.
>
> JB> The Perl question could be, which CPAN module can be used to
> accomplish
>
> why even use a module? the getXXbyXX functions support basic reverse
> dns lookups.


Tested this, but it doesn't return virtual hosts on a given IP address. No
idea if Net:NS suffers from the same problem.


--
John Experienced Perl programmer: http://castleamber.com/

Perl help, tutorials, and examples: http://johnbokma.com/perl/
 
Reply With Quote
 
Ben Morrow
Guest
Posts: n/a
 
      08-18-2006

Quoth John Bokma <(E-Mail Removed)>:
> Uri Guttman <(E-Mail Removed)> wrote:
>
> >>>>>> "JB" == John Bokma <(E-Mail Removed)> writes:

> >
> > JB> (E-Mail Removed) wrote:
> > >> (E-Mail Removed) wrote:
> > >>> Does anybody know how to perform a reverse dns that returns the
> > >>> number of domains associated with a certain IP? Thanks
> > >>
> > >> No.
> > >>
> > >> DNS does not work that way... hint... domains do not have IP
> > >> numbers.

> >
> > JB> What the OP means (guess) is that for a given IP address he
> > wants to JB> get a list of all domains that are hosted on that
> > address.
> >
> > JB> The Perl question could be, which CPAN module can be used to
> > accomplish
> >
> > why even use a module? the getXXbyXX functions support basic reverse
> > dns lookups.

>
> Tested this, but it doesn't return virtual hosts on a given IP address. No
> idea if Net:NS suffers from the same problem.


Well... yes. DNS Doesn't Work Like That. Given an IP address, all you
can do is look it up in .in-addr.arpa., in which case what you get is at
most one PTR to (if you're lucky) the canonical hostname for that
address.

The only way to find all the hostnames that resolve to a given ip is to
trawl the *whole* of the DNS and grep out the appropriate entries. Not
something I'd recommend trying...

Ben

--
Outside of a dog, a book is a man's best friend.
Inside of a dog, it's too dark to read.
(E-Mail Removed) Groucho Marx
 
Reply With Quote
 
Peter J. Holzer
Guest
Posts: n/a
 
      08-19-2006
On Sat, 19 Aug 2006 00:03:55 +0100, Ben Morrow wrote:
> Quoth John Bokma <(E-Mail Removed)>:
>> Uri Guttman <(E-Mail Removed)> wrote:
>> >>>>>> "JB" == John Bokma <(E-Mail Removed)> writes:
>> > JB> (E-Mail Removed) wrote:
>> > >> (E-Mail Removed) wrote:
>> > >>> Does anybody know how to perform a reverse dns that returns the
>> > >>> number of domains associated with a certain IP? Thanks

[...]
>> > why even use a module? the getXXbyXX functions support basic reverse
>> > dns lookups.

>>
>> Tested this, but it doesn't return virtual hosts on a given IP address. No
>> idea if Net:NS suffers from the same problem.


DNS doesn't have the concept of "virtual hosts" or "hosting" in general.
It's just a hierarchical directory structure where every node may have
some information (e.g., IP-addresses, texts, service information,
location information, ...) associated with it.


> Well... yes. DNS Doesn't Work Like That. Given an IP address, all you
> can do is look it up in .in-addr.arpa., in which case what you get is at
> most one PTR to (if you're lucky) the canonical hostname for that
> address.


Nope. The number of PTR records is not limited. For example,
dig 2.20.130.143.in-addr.arpa. ptr
returns three of them.

But there is no guarantee that there is a corresponding PTR record for
every A record - the correspondence exists only by convention, and it is
infeasible in some situations (e.g., if thousands of FQDNs resolve to
the same IP address, you don't want to return thousands of PTR records
to every query).

> The only way to find all the hostnames that resolve to a given ip is to
> trawl the *whole* of the DNS and grep out the appropriate entries. Not
> something I'd recommend trying...


Doesn't work, since most most nameservers don't answer AXFR requests
from untrusted clients anymore. I used to do that kind of thing for some
of the smaller TLDs in the 1990's .

hp

--
_ | Peter J. Holzer | > Wieso sollte man etwas erfinden was nicht
|_|_) | Sysadmin WSR | > ist?
| | | (E-Mail Removed) | Was sonst wäre der Sinn des Erfindens?
__/ | http://www.hjp.at/ | -- P. Einstein u. V. Gringmuth in desd

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
OE6-Blockage-and Reverse DNS ellis_jay Computer Support 5 06-30-2005 07:28 PM
reverse DNS lookup =?Utf-8?B?RGFuIE5hc2g=?= ASP .Net 0 10-14-2004 09:05 AM
performing reverse DNS lookup with InetAddress Madhur Ahuja Java 1 08-29-2004 07:57 AM
DNS question - reverse DNS getting cluttered Jose Padilla Computer Support 0 01-21-2004 10:29 PM
Stacks Queues Reverse Reverse Polish dogbite C++ 4 10-10-2003 05:06 AM



Advertisments