ip

package
v0.0.0-...-4573a4b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 4, 2024 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddrPortMappedEqual

func AddrPortMappedEqual(l, r netip.AddrPort) bool

AddrPortMappedEqual returns whether the two addresses point to the same endpoint. An IPv4 address and an IPv4-mapped IPv6 address pointing to the same endpoint are considered equal. For example, 1.1.1.1:53 and [::ffff:1.1.1.1]:53 are considered equal.

func AddrPortMappedEqualUnsafe

func AddrPortMappedEqualUnsafe(l, r netip.AddrPort) bool

func AddrPortv4Mappedv6

func AddrPortv4Mappedv6(addrPort netip.AddrPort) netip.AddrPort

AddrPortv4Mappedv6 converts an IPv4 address to an IPv4-mapped IPv6 address. This function does nothing if addrPort is an IPv6 address.

func AddrPortv4Mappedv6Unsafe

func AddrPortv4Mappedv6Unsafe(addrPort netip.AddrPort) netip.AddrPort

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL