Contiki-NG
Data Structures | Macros
uip-nd6.h File Reference

Header file for IPv6 Neighbor discovery (RFC 4861) More...

#include "net/ipv6/uip.h"
#include "sys/stimer.h"

Go to the source code of this file.

Data Structures

struct  uip_nd6_ns
 A neighbor solicitation constant part. More...
 
struct  uip_nd6_na
 A neighbor advertisement constant part. More...
 
struct  uip_nd6_rs
 A router solicitation constant part. More...
 
struct  uip_nd6_ra
 A router advertisement constant part. More...
 
struct  uip_nd6_redirect
 A redirect message constant part. More...
 
struct  uip_nd6_opt_hdr
 ND option header. More...
 
struct  uip_nd6_opt_prefix_info
 ND option prefix information. More...
 
struct  uip_nd6_opt_mtu
 ND option MTU. More...
 
struct  uip_nd6_opt_dns
 ND option RDNSS. More...
 

Macros

#define UIP_ND6_DEF_MAXDADNS   UIP_ND6_SEND_NS
 Do not try DAD when using EUI-64 as allowed by draft-ietf-6lowpan-nd-15 section 8.2.
 
General
#define UIP_ND6_HOP_LIMIT   255
 HOP LIMIT to be used when sending ND messages (255)
 
#define UIP_ND6_INFINITE_LIFETIME   0xFFFFFFFF
 INFINITE lifetime.
 
RFC 4861 Host constant
#define UIP_ND6_MAX_RTR_SOLICITATION_DELAY   1
 Maximum router solicitation delay.
 
#define UIP_ND6_RTR_SOLICITATION_INTERVAL   4
 Router solicitation interval.
 
#define UIP_ND6_MAX_RTR_SOLICITATIONS   3
 Maximum router solicitations.
 
RFC 4861 Router constants
#define UIP_ND6_SEND_RA   1 /* enable/disable RA sending */
 
#define UIP_ND6_SEND_NS   1 /* enable/disable NS sending */
 
#define UIP_ND6_SEND_NA   1 /* enable/disable NA sending */
 
#define UIP_ND6_AUTOFILL_NBR_CACHE   0
 
#define UIP_ND6_MAX_RA_INTERVAL   600
 
#define UIP_ND6_MIN_RA_INTERVAL   (UIP_ND6_MAX_RA_INTERVAL / 3)
 
#define UIP_ND6_M_FLAG   0
 
#define UIP_ND6_O_FLAG   0
 
#define UIP_ND6_ROUTER_LIFETIME   3 * UIP_ND6_MAX_RA_INTERVAL
 
#define UIP_ND6_MAX_INITIAL_RA_INTERVAL   16 /*seconds*/
 
#define UIP_ND6_MAX_INITIAL_RAS   3 /*transmissions*/
 
#define UIP_ND6_MIN_DELAY_BETWEEN_RAS   3 /*seconds*/
 
#define UIP_ND6_MAX_RA_DELAY_TIME_MS   500 /*milli seconds*/
 
RFC 4861 Node constant
#define UIP_ND6_MAX_MULTICAST_SOLICIT   3
 
#define UIP_ND6_MAX_UNICAST_SOLICIT   3
 
#define UIP_ND6_REACHABLE_TIME   60000
 
#define UIP_ND6_RETRANS_TIMER   1000
 
#define UIP_ND6_DELAY_FIRST_PROBE_TIME   5
 
#define UIP_ND6_MIN_RANDOM_FACTOR(x)   (x / 2)
 
#define UIP_ND6_MAX_RANDOM_FACTOR(x)   ((x) + (x) / 2)
 
RFC 6106 RA DNS Options Constants
#define UIP_ND6_RA_RDNSS   0
 
#define UIP_ND6_RA_DNSSL   0
 
ND6 option types
#define UIP_ND6_OPT_SLLAO   1
 
#define UIP_ND6_OPT_TLLAO   2
 
#define UIP_ND6_OPT_PREFIX_INFO   3
 
#define UIP_ND6_OPT_REDIRECTED_HDR   4
 
#define UIP_ND6_OPT_MTU   5
 
#define UIP_ND6_OPT_RDNSS   25
 
#define UIP_ND6_OPT_DNSSL   31
 
#define UIP_ND6_OPT_TYPE_OFFSET   0
 
#define UIP_ND6_OPT_LEN_OFFSET   1
 
#define UIP_ND6_OPT_DATA_OFFSET   2
 
ND6 message length (excluding options)
#define UIP_ND6_NA_LEN   20
 
#define UIP_ND6_NS_LEN   20
 
#define UIP_ND6_RA_LEN   12
 
#define UIP_ND6_RS_LEN   4
 
ND6 option length in bytes
#define UIP_ND6_OPT_HDR_LEN   2
 
#define UIP_ND6_OPT_PREFIX_INFO_LEN   32
 
#define UIP_ND6_OPT_MTU_LEN   8
 
#define UIP_ND6_OPT_RDNSS_LEN   1
 
#define UIP_ND6_OPT_DNSSL_LEN   1
 
#define UIP_ND6_OPT_LLAO_LEN   8
 length of a ND6 LLAO option for default L2 type (e.g. More...
 
Neighbor Advertisement flags masks
#define UIP_ND6_NA_FLAG_ROUTER   0x80
 
#define UIP_ND6_NA_FLAG_SOLICITED   0x40
 
#define UIP_ND6_NA_FLAG_OVERRIDE   0x20
 
#define UIP_ND6_RA_FLAG_ONLINK   0x80
 
#define UIP_ND6_RA_FLAG_AUTONOMOUS   0x40
 

Typedefs

ND message structures
typedef struct uip_nd6_ns uip_nd6_ns
 A neighbor solicitation constant part. More...
 
typedef struct uip_nd6_na uip_nd6_na
 A neighbor advertisement constant part. More...
 
typedef struct uip_nd6_rs uip_nd6_rs
 A router solicitation constant part. More...
 
typedef struct uip_nd6_ra uip_nd6_ra
 A router advertisement constant part. More...
 
typedef struct uip_nd6_redirect uip_nd6_redirect
 A redirect message constant part. More...
 
ND Option structures
typedef struct uip_nd6_opt_hdr uip_nd6_opt_hdr
 ND option header.
 
typedef struct uip_nd6_opt_prefix_info uip_nd6_opt_prefix_info
 ND option prefix information.
 
typedef struct uip_nd6_opt_mtu uip_nd6_opt_mtu
 ND option MTU.
 
typedef struct uip_nd6_opt_dns uip_nd6_opt_dns
 ND option RDNSS.
 
typedef struct uip_nd6_opt_redirected_hdr uip_nd6_opt_redirected_hdr
 

Functions

ND Messages Processing and Generation
void uip_nd6_ns_output (uip_ipaddr_t *src, uip_ipaddr_t *dest, uip_ipaddr_t *tgt)
 Send a neighbor solicitation, send a Neighbor Advertisement. More...
 
void uip_nd6_rs_output (void)
 Send a Router Solicitation. More...
 
void uip_nd6_init (void)
 Initialise the uIP ND core.
 

Detailed Description

Header file for IPv6 Neighbor discovery (RFC 4861)

Author
Julien Abeille jabei.nosp@m.lle@.nosp@m.cisco.nosp@m..com
Mathilde Durvy mdurv.nosp@m.y@ci.nosp@m.sco.c.nosp@m.om

Definition in file uip-nd6.h.