Re: Application tool to acquire all ipv6 addresses on a specified int erface
Jeroen Massar <[email protected]>
| Newsgroups | gmane.network.ipv6.general,gmane.linux.ipv6.usagi.users |
|---|---|
| Organization | Unfix |
| Message-ID | <[email protected]> |
On Fri, 2005-05-06 at 08:29 -0400, Bellino, Phil wrote: > Hello, > I am running 2.6.11 linux and have IPv6 addresses on eth0, eth1, tun6to4, > etc. > > I am looking for a tool that my applcation can use that will give me back > all of the IPv6 addresses that are on a specified interface. > I am trying to prevent having to execute a shell command(such as "ip" or > "ifconfig") and then having to parse all that is returned for the IPv6 > addresses in question. > > Does anyone know of such a tool? It is called 'cat', or grep if you want a single entry jeroen@purgatory:~$ cat /proc/net/if_inet6 00000000000000000000000000000001 02 80 10 80 lo fe800000000000000a002bfffee702b3 03 40 20 80 eth1 200107b8000500100f71000000000002 03 50 00 80 eth1 200107b803000000029027fffe24c19f 01 40 00 80 eth0 fe80000000000000029027fffe24c19f 01 40 20 80 eth0 Notez bien, this will only work on linux and not any other platform. Then again doing it crossplatform is I guess almost impossible anyway except if one codes a part for every separate OS. Greets, Jeroen
signature.asc
(application/pgp-signature, 240 B)
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) Comment: Jeroen Massar / http://unfix.org/~jeroen/ iD8DBQBCfiU0KaooUjM+fCMRAvmNAJ9v+NtBhupuP92RfZcN6oa/Bn4dhQCdFIxr lUSggpaJhQthE3d4FcULLDo= =FktG -----END PGP SIGNATURE-----