North American Network Operators Group

Date Prev | Date Next | Date Index | Thread Index | Author Index | Historical

Re: interger to I P address

  • From: Jeroen Massar
  • Date: Wed Aug 27 07:20:21 2008

Simon Lockhart wrote:
> On Wed Aug 27, 2008 at 07:11:41AM -0400, kcc wrote:
>> ls it possible t convert the interger to ip
> 
> Yes.

If you are using 128-bit integers, which according to some will also
change some day, thus one should be using "struct addrinfo" and:

getaddrinfo()
getnameinfo()

as those are the girlfriends of programmers.

Note that one should effectively avoid inet_pton/inet_ntop as they still
require the programmer to know about address families, the get*info()
ones ignore all those details.

Also see Itojun's (RIP :( ) excellent document at:
 http://www.kame.net/newsletter/19980604/

and of course Eva's document at:
 http://gsyc.escet.urjc.es/~eva/IPv6-web/ipv6.html

Greets,
 Jeroen

Attachment: signature.asc
Description: OpenPGP digital signature