icap

package
v0.0.0-...-8d7cf1a Latest Latest
Warning

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

Go to latest
Published: Jun 17, 2026 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ScanResult

type ScanResult struct {
	Server     string `json:"server"`
	Infected   bool   `json:"infected"`
	Threat     string `json:"threat,omitempty"`
	DurationMs int64  `json:"duration_ms"`
}

ScanResult holds the result of scanning a file against an ICAP server.

func ScanFile

func ScanFile(serverURL string, fileData []byte) (*ScanResult, error)

ScanFile sends a file to an external ICAP server for scanning.

type Server

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

Server is a minimal ICAP server that submits received files for scanning.

func New

func New(addr string) *Server

New creates an ICAP server listening on the given address.

func (*Server) Start

func (s *Server) Start() error

Start begins listening for ICAP connections.

func (*Server) Stop

func (s *Server) Stop()

Stop closes the listener.

Jump to

Keyboard shortcuts

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