I have to write a perl script that keeps track of tcp connections.  I
plan to keep track of this in an array of the form
tcp_connection[source address][dest address]

To do this I want to convert an IP address of the form A.B.C.D into a
number that will serve as an index of the array.  I want to do it in a
way that there is very low probability of the number created from
A.B.C.D being the same as that created from E.F.G.H.

One way is to create a MD5 hash with input as A.B.C.D etc.

Is there any way to do this in perl?


-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
http://learn.perl.org/


Reply via email to