std1.0.0-beta-7 SafeC docs

Module net::ipv6

#include <std/net/ipv6.h> source

IPv6 Layer Parse and build IPv6 headers. Freestanding-safe.

Structs

Ipv6Addr
Ipv6Hdr

Functions

ipv6_addr_eqCompare two IPv6 addresses. Returns 1 if equal.
ipv6_addr_is_unspecifiedIs address the all-zeros (unspecified) address?
ipv6_addr_is_loopbackIs address a loopback (::1)?
ipv6_addr_is_link_localIs address a link-local (fe80::/10)?
ipv6_addr_strFormat IPv6 address into buf as "xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx\0" (40 bytes).
ipv6_parseParse IPv6 header from pkt at byte offset offset. Returns 0 on success, -1 on truncation.
ipv6_buildWrite IPv6 header into pkt at byte offset offset. Returns byte offset of first payload byte.
ipv6_frameIPv6-over-Ethernet full frame helper (Ethernet + IPv6 header, caller writes payload). Returns offset where payload should be written.

Macros

IPV6_HDR_LENfixed header length
IPV6_ADDR_LENbytes in an IPv6 address