internal

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2023 License: GPL-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IPSet

type IPSet interface {
	Create(name string, ttl time.Duration) error
	Close() error
	AddAddr(name string, addr netip.Addr, ttl time.Duration) error
	AddPrefix(name string, prefix netip.Prefix, ttl time.Duration) error
	DelAddr(name string, addr netip.Addr) error
	DelPrefix(name string, prefix netip.Prefix) error
	Flushall(name string) error
	Destroy(name string) error
}

func New

func New() (IPSet, error)

type IPSetLinux

type IPSetLinux struct {
	// contains filtered or unexported fields
}

func (*IPSetLinux) AddAddr

func (i *IPSetLinux) AddAddr(name string, addr netip.Addr, ttl time.Duration) error

func (*IPSetLinux) AddPrefix

func (i *IPSetLinux) AddPrefix(name string, prefix netip.Prefix, ttl time.Duration) error

func (*IPSetLinux) Close

func (i *IPSetLinux) Close() error

func (*IPSetLinux) Create

func (i *IPSetLinux) Create(name string, ttl time.Duration) error

func (*IPSetLinux) DelAddr

func (i *IPSetLinux) DelAddr(name string, addr netip.Addr) error

func (*IPSetLinux) DelPrefix

func (i *IPSetLinux) DelPrefix(name string, prefix netip.Prefix) error

func (*IPSetLinux) Destroy

func (i *IPSetLinux) Destroy(name string) error

func (*IPSetLinux) Flushall

func (i *IPSetLinux) Flushall(name string) error

Jump to

Keyboard shortcuts

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