public
Description: Ruby gem which process flat files from IANA
Homepage: http://iana.rubyforge.org/
Clone URL: git://github.com/yesmar/iana.git
iana /
name age message
file .gitignore Sat Feb 23 21:50:48 -0800 2008 release 0.0.2 [yesmar]
file COPYRIGHT Sat Feb 23 21:26:05 -0800 2008 updated COPYRIGHT; tagged release [Ramsey Dow]
file HISTORY Sat Feb 23 22:18:52 -0800 2008 release 0.0.4 [yesmar]
file LICENSE Sat Feb 23 18:46:21 -0800 2008 added MIT license [Ramsey Dow]
file README Sun Feb 24 02:21:16 -0800 2008 updated README [yesmar]
file Rakefile Mon Feb 25 19:32:42 -0800 2008 Updated gem spec in Rakefile [yesmar]
directory examples/ Sat Feb 23 18:38:04 -0800 2008 initial commit [Ramsey Dow]
directory lib/ Sun Feb 24 23:19:08 -0800 2008 added ahsan's cool TODO functionality to Rakefi... [yesmar]
README
== What
IANA Ruby module version 0.0.4

I like to look stuff up, like TCP/IP port numbers, protocols, top-level
domains, et al. I get my data from the Internet Assigned Numbers Authority
(IANA) and like to make it available to my programs. Since I am open sourcing
this code you can add this functionality to your own programs as well.

== How
require 'rubygems'
require 'iana'

The IANA Ruby module loads the data into conveniently searchable data
structures. The flat files the IANA Ruby module consume as data are hosted at
iana.org. You will need to fetch them so you can process the content locally.
I grab these files with with curl (but you can use wget or whatever if you
don't use curl):

curl -O http://www.iana.org/assignments/port-numbers
curl -O http://www.iana.org/assignments/protocol-numbers
curl -O http://data.iana.org/TLD/tlds-alpha-by-domain.txt

== Examples
When you run the example programs, do it like so:

  ruby examples/ports.rb port-numbers

Use these example programs to see how you might use and otherwise integrate
IANA data functionality into your own programs.

== Install
I added a Rakefile and a gem spec. To build the gem, just type:

  rake gem

To install the gem, just type:

  sudo gem install pkg/iana-0.0.4.gem

== Notes
I haven't tested this code with YARV, so YMMV.

== Contribute
The source is availble at github: git://github.com/yesmar/iana.git. Feel free
to clone it and implement your own awesome ideas. You can also send your
patches by email to yesmar[at]speakeasy[dot]net.