firewall

package
v1.1.7 Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2025 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Initialization added in v1.0.5

func Initialization(runAsDaemon bool)

Types

type Firewall added in v1.0.5

type Firewall interface {
	Block(ctx context.Context, ip string)
	Worker()
	UnlockAll(ctx context.Context) (ips int, err error)

	GetBlocked() map[string]struct{}
	// contains filtered or unexported methods
}
var ExportFirewall Firewall

func Do added in v1.0.5

func Do() Firewall

type Mock added in v1.0.5

type Mock struct{}

func (*Mock) Block added in v1.0.5

func (fw *Mock) Block(ctx context.Context, ip string)

func (*Mock) GetBlocked added in v1.1.5

func (fw *Mock) GetBlocked() map[string]struct{}

func (*Mock) UnlockAll added in v1.0.5

func (fw *Mock) UnlockAll(ctx context.Context) (ips int, err error)

func (*Mock) Worker added in v1.0.5

func (fw *Mock) Worker()

Jump to

Keyboard shortcuts

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