HI all,
I am writing simple dhcpv6 client. I
gone through the rfc of dhcp and ipv6 and understand basic.
With the understanding i started to implement SOLICIT request
option.
I have created a packet with the below structure.
struct udp_dhcp6_packet {
struct ip6_hdr ip;
struct udphdr udp;
struct dhcp6_Message data;
} PACKED;
In the above structure i am able to assign the value for udp and data(i.e struct udphdr, struct dhcp6_Message). But i could not able to set the value for ip. Below is the structure of ip6_hdr.
struct ip6_hdr
{
union {
I want to set the ip6_dst value as ff02::1:2 and the ip6_src address as fe80::220:4aff:fea8:8e4a and remaining options. But i dont have any idea how to set these values. I googled many times and not able to get the idea to creat ipv6 header.
Kindly help me to solve my problem?
Note :
I don't know whether this is right place to ask this question . If i am wrong , i am sorry.
Thanks in advance ,
Prabhu