|
NetBurner 3.5.6
PDF Version |
Main IPv6 interface management class. More...
#include <ipv6_interface.h>
Inherits TimeOutElement.
Public Member Functions | |
| uint16_t | GetDestinationMTU (const IPADDR &ip) |
| Get destination MTU for specified address. | |
| IPv6Interface * | GetNext_IP6_Interface () |
| Get next IPv6 interface in the list. | |
| IPADDR6 | MySourceAddress (const IPADDR6 &ip) |
| Determine best source address for communicating with destination. | |
| int | GetInterfaceNumber () |
| Get interface number. | |
| IPADDR6 | MyDNSAddress () |
| Get DNS server address for this interface. | |
| bool | HadLink () |
| Check if interface has had link connectivity. | |
| IPV6_PREFIX * | AddStaticAddress (const IPADDR6 &ip, int PrefixLen) |
| Add static IPv6 address to interface. | |
| IPV6_ROUTER * | AddDefaultGateway (const IPADDR6 &ip) |
| Add default gateway to interface. | |
| IPV6_DNS * | AddStaticDNS (const IPADDR6 &ip) |
| Add static DNS server to interface. | |
| bool | RemoveStaticAddress (const IPADDR6 &ip) |
| Remove static IPv6 address from interface. | |
| bool | RemoveDefaultGateway (const IPADDR6 &ip) |
| Remove default gateway from interface. | |
| bool | RemoveStaticDNS (const IPADDR6 &ip) |
| Remove static DNS server from interface. | |
| void | SetStaticDNS (IPADDR6 dns) |
| Set static DNS server address. | |
| void | StartDHCP_Solicit () |
| Start DHCPv6 solicitation process. | |
| void | StartDHCP_InfoReq () |
| Start DHCPv6 information request process. | |
| bool | IsMyAddress (const IPADDR6 &ip6, bool bMustBePrefered) |
| Check if IPv6 address belongs to this interface. | |
| bool | OnLink (const IPADDR6 &ip6) |
| Check if IPv6 address is on-link for this interface. | |
| bool | HasRoute (const IPADDR6 &ip6) |
| Check if there is a route to the specified IPv6 address. | |
| void | NotifyReachable (const IPADDR6 &ip6) |
| Notify that neighbor is reachable. | |
| void | NotifyUnreachable (const IPADDR6 &ip) |
| Notify that neighbor is unreachable. | |
| IPADDR6 | GetMyFirstAddress () |
| Get first configured IPv6 address. | |
| IPADDR6 | GetMyNextAddress (const IPADDR6 &ip) |
| Get next IPv6 address after specified address. | |
| IPv6Interface (int ifnum) | |
| Constructor for IPv6 interface. | |
| int | ping (const IPADDR6 &ip, uint16_t id, uint16_t seq, uint16_t wait, int siz) |
| Send IPv6 ping to specified address. | |
| int | SendMLDRegistration (const IPADDR ®Addr, bool joinNotLeave=true) |
| Send MLD registration message. | |
| void | ShowInfo () |
| Display IPv6 information for this interface. | |
Static Public Member Functions | |
| static IPv6Interface * | GetInterfaceForDestination (const IPADDR6 &ip) |
| Find interface that can reach the specified destination. | |
| static IPv6Interface * | GetInterfaceForSource (const IPADDR6 &ip) |
| Find interface that should be used as source for specified destination. | |
| static IPv6Interface * | GetInterfaceN (int n) |
| Get IPv6 interface by interface number. | |
| static IPv6Interface * | GetFirst_IP6_Interface () |
| Get first IPv6 interface in the system. | |
| static void | ShowAllInfo () |
| Display IPv6 information for all interfaces. | |
Public Attributes | |
| IPV6_PREFIX * | m_pMyLinkLocal |
| Link-local address for this interface. | |
| IPADDR6 | m_StaticDNS |
| Static DNS server address. | |
Friends | |
| struct | IPV6_PREFIX |
| struct | IPV6_DEST |
| struct | IPV6_ROUTER |
| struct | IPV6_NEIGHBOR |
| struct | IPV6_DNS |
| struct | IPV6_DHCPD |
| class | UDPPacket |
| void | InitIPv6 (int ifnum=0) |
| int | Ping6 (const IPADDR6 &to, uint16_t id, uint16_t seq, uint16_t maxwaitticks, int size=32) |
| Send an IPv6 "ping" packet and wait the specified timeout for a response. | |
Main IPv6 interface management class.
Provides comprehensive IPv6 interface functionality including address management, routing, neighbor discovery, and protocol processing.
| IPv6Interface::IPv6Interface | ( | int | ifnum | ) |
Constructor for IPv6 interface.
| ifnum | Interface number |
| IPV6_ROUTER * IPv6Interface::AddDefaultGateway | ( | const IPADDR6 & | ip | ) |
Add default gateway to interface.
| ip | IPv6 address of default gateway |
| IPV6_PREFIX * IPv6Interface::AddStaticAddress | ( | const IPADDR6 & | ip, |
| int | PrefixLen ) |
Add static IPv6 address to interface.
| ip | IPv6 address to add |
| PrefixLen | Prefix length in bits |
Add static DNS server to interface.
| ip | IPv6 address of DNS server |
| uint16_t IPv6Interface::GetDestinationMTU | ( | const IPADDR & | ip | ) |
Get destination MTU for specified address.
| ip | Destination IP address |
|
static |
Get first IPv6 interface in the system.
|
static |
Find interface that can reach the specified destination.
| ip | Destination IPv6 address |
|
static |
Find interface that should be used as source for specified destination.
| ip | Destination IPv6 address |
|
static |
Get IPv6 interface by interface number.
| n | Interface number |
|
inline |
Get interface number.
|
inline |
Get first configured IPv6 address.
Get next IPv6 address after specified address.
| ip | Current IPv6 address |
| IPv6Interface * IPv6Interface::GetNext_IP6_Interface | ( | ) |
Get next IPv6 interface in the list.
|
inline |
Check if interface has had link connectivity.
| bool IPv6Interface::HasRoute | ( | const IPADDR6 & | ip6 | ) |
Check if there is a route to the specified IPv6 address.
| ip6 | Destination IPv6 address |
| bool IPv6Interface::IsMyAddress | ( | const IPADDR6 & | ip6, |
| bool | bMustBePrefered ) |
Check if IPv6 address belongs to this interface.
| ip6 | IPv6 address to check |
| bMustBePrefered | true if address must be in preferred state |
| IPADDR6 IPv6Interface::MyDNSAddress | ( | ) |
Get DNS server address for this interface.
Determine best source address for communicating with destination.
| ip | Destination IPv6 address |
| void IPv6Interface::NotifyReachable | ( | const IPADDR6 & | ip6 | ) |
Notify that neighbor is reachable.
| ip6 | IPv6 address of reachable neighbor |
| void IPv6Interface::NotifyUnreachable | ( | const IPADDR6 & | ip | ) |
Notify that neighbor is unreachable.
| ip | IPv6 address of unreachable neighbor |
| bool IPv6Interface::OnLink | ( | const IPADDR6 & | ip6 | ) |
Check if IPv6 address is on-link for this interface.
| ip6 | IPv6 address to check |
| int IPv6Interface::ping | ( | const IPADDR6 & | ip, |
| uint16_t | id, | ||
| uint16_t | seq, | ||
| uint16_t | wait, | ||
| int | siz ) |
Send IPv6 ping to specified address.
| ip | Destination IPv6 address |
| id | Ping identifier |
| seq | Ping sequence number |
| wait | Maximum wait time in ticks |
| siz | Ping packet size |
| bool IPv6Interface::RemoveDefaultGateway | ( | const IPADDR6 & | ip | ) |
Remove default gateway from interface.
| ip | IPv6 address of gateway to remove |
| bool IPv6Interface::RemoveStaticAddress | ( | const IPADDR6 & | ip | ) |
Remove static IPv6 address from interface.
| ip | IPv6 address to remove |
| bool IPv6Interface::RemoveStaticDNS | ( | const IPADDR6 & | ip | ) |
Remove static DNS server from interface.
| ip | IPv6 address of DNS server to remove |
| int IPv6Interface::SendMLDRegistration | ( | const IPADDR & | regAddr, |
| bool | joinNotLeave = true ) |
Send MLD registration message.
| regAddr | Multicast address to register |
| joinNotLeave | true to join, false to leave |
|
inline |
Set static DNS server address.
| dns | IPv6 address of DNS server |
|
static |
Display IPv6 information for all interfaces.
| void IPv6Interface::ShowInfo | ( | ) |
Display IPv6 information for this interface.
|
friend |
|
friend |
Send an IPv6 "ping" packet and wait the specified timeout for a response.
Sends an ICMPv6 echo request packet to the specified IPv6 destination address and waits for an echo reply. The ping uses the primary network interface. This follows the ICMPv6 echo request/reply protocol defined in RFC 4443.
| to | Destination IPv6 address to ping |
| id | ICMP identifier field (typically process ID) |
| seq | ICMP sequence number field (typically increments per ping) |
| maxwaitticks | Maximum wait time in system time ticks |
| size | Size of ping data payload in bytes (default: 32) |