MAC address of an IPv6 address

Hi All,

I am writing a program that tests the health of a NIC card. I am creating a NDD socket (Data Link Access) which I will use to send ICMP ECHO packets to a given host. This means that my application has to build the entire packet and I have to create and add the IP/IPv6, ICMP/

6, and MAC headers in my application. I got things to work for IP, but I am stuck with IPv6:

1) How do I find the MAC address for an IPv6 remote host? For IP, I use the SIOCGARP ioctl and get the MAC adress from the ARP cache. But IPv6 does not use ARP. there is something called neighbor discovery for IPv6, but I could not find any programatic interface to use it ..

2) How do I do a broadcast ping in IPv6? In v4, I just put the broadcast address in the destination addr fiend of the IP header and things worked, but what do I do for v6?

Thanks in advance for your help.

Jigs

Reply to
Jigs
Loading thread data ...

Try posting to comp.protocols.tcp-ip.

There is no such thing as broadcast in IPv6. There are only multicast addresses. You'd have to use one of these such as the "all nodes" multicast address to reach all nodes on the local link.

Anoop

Reply to
anoop

Cabling-Design.com Forums website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.