scripts to map IP to AS?

### casually decided to expound upon "David G. Andersen" <dga@lcs.mit.edu>,
### William Allen Simpson <wsimpson@greendragon.com> the following thoughts
### about "Re: scripts to map IP to AS?":

Dave (and anyone that downloads lookup_as.c),

Grab a newer version of traceroute.c -- There is a CLASSFULL piece of code
within the 2.9.3 code-base used in lookup_as.c. The newer traceroute.c
code removes the 192/8 & 128/8 testing. This is a cut-n-paste from the
newer traceroute-nanog-6.3.0/traceroute.c. It can be cut-n-pasted into
your code...

Just a reminder to everyone who intends to query the IRR/RADB... Please be
nice to the RADB whois server and don't DoS it. Open a persistant
connection instead of one for each prefix lookup. For RADB and any other
IRR server running IRRd, this can be accomplished by sending a "!!" in the
beginning and keeping the connection open on your end in a seperate thread
or something that you then issue the query to. For RIPE Whois based IRR
servers, use the "-k" flag.

Are there any recommendations for caching of the results? Do, don't, not for
over 72 hours, etc? I think most people that do an AS-enabled traceroute
are always going to be getting the same answers back for the first few hops
to *ANYWHERE* - caching at least "your local neighborhood" could dramatically
cut the number of queries....

Date: Thu, 20 Feb 2003 15:25:52 -0500
From: Valdis.Kletnieks

Just a reminder to everyone who intends to query the
IRR/RADB... Please be nice to the RADB whois server and
don't DoS it. Open a persistant connection instead of one

Are there any recommendations for caching of the results? Do,
don't, not for over 72 hours, etc? I think most people that
do an AS-enabled traceroute are always going to be getting
the same answers back for the first few hops to *ANYWHERE* -
caching at least "your local neighborhood" could dramatically
cut the number of queries....

Better yet, a DNS authd that resolves

  origin-asn.1.0.0.127.in-addr.arpa IN TXT

appropriately.

Eddy