HP-UX IPv6 Porting Guide (September 2004)

Table Of Contents
Contents
vi
Syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53
Returning All Interface Names and Indexes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53
Freeing Memory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
Header Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
Syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
13. Configuring or Querying an Interface using IPv6 ioctl() Function Calls
14. Verifying IPv6 Installation
15. Sample Client/Server Programs
IPv4 TCP Client Code Fragment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
IPv6 TCP Client using getipnodebyname() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
IPv6 TCP Client Using getaddrinfo() for Name/Service Lookup. . . . . . . . . . . . . . . . . . 64
IPv4 TCP Server Code Fragment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
IPv6 TCP Server using getaddrinfo() for Service Address Lookup . . . . . . . . . . . . . . . . 66
Do Existing IPv4-to-IPv4 Applications Require Changes? . . . . . . . . . . . . . . . . . . . . . . 70
Summary: Source Code Symbols and Function Changes . . . . . . . . . . . . . . . . . . . . . . . 71
Changes to Symbols, Data Structures, and Function Calls . . . . . . . . . . . . . . . . . . . . 71
Watch for hard-coded data structure sizes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
Multicast and IPv4 Options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
Loopback Address . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
Wildcard Address . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
Multicast Defaults . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
IPv6 Multicast Options. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73
IP Packet Options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73
Types of Service Options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 74
Multicast Group, IP Address, and IPv6 Interface Index . . . . . . . . . . . . . . . . . . . . . . 74