rbl

package
v0.0.0-...-963a1a8 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2025 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RBL

type RBL struct {
	Results []Result
	// contains filtered or unexported fields
}

Rbl ... object

func New

func New(util *dns.DNSUtil, logger *slog.Logger) *RBL

NewRbl ... factory

func (*RBL) Update

func (rbl *RBL) Update(target Target, blocklist string, c chan<- Result)

Update runs the checks for an IP against against all "rbls"

type Resolver

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

func NewRBLResolver

func NewRBLResolver(logger *slog.Logger, util *dns.DNSUtil) *Resolver

func (*Resolver) Do

func (r *Resolver) Do(target string, c chan<- Target, done func())

type Result

type Result struct {
	Target    Target
	Listed    bool
	Text      string
	Error     bool
	ErrorType error
	Rbl       string
}

RblResult extends godnsbl and adds RBL name

type Target

type Target struct {
	Host string
	IP   net.IP
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳