Files
traefik-botfilter/botfilter.go
T
2026-05-11 16:30:00 +08:00

24 lines
373 B
Go

// Package traefik_botfilter is a Traefik middleware plugin that blocks known scans
// and applies a bounded, in-memory per-IP suspicion score.
package botfilter
import (
"bufio"
"context"
"fmt"
"io"
"net"
"net/http"
"net/netip"
"strconv"
"time"
)
type botFilter struct {
next http.Handler
config *compiledConfig
cache *clientCache
logger filterLogger
}