Documentation ¶
Index ¶
- Constants
- func CheckSum(data []byte) uint16
- func IPtoByte(ipStr string) [4]byte
- func IsPseudo(key string) bool
- func IsValidDir(dirPath string) error
- type DeviceListener
- type FileDirInput
- type FileDirOutput
- type FileDirOutputConfig
- type GRPCOutput
- type OutputKafkaConfig
- type PsdHeader
- type RAWInput
- type ReinforcedReader
- type SASLKafkaConfig
- type StdOutput
- type TCPHeader
Constants ¶
View Source
const ( FIN = 1 << iota SYN RST PSH ACK URG )
Variables ¶
This section is empty.
Functions ¶
func IsValidDir ¶
Types ¶
type DeviceListener ¶
type DeviceListener struct {
// contains filtered or unexported fields
}
func NewDeviceListener ¶
func NewDeviceListener(device string, port int, rawInput *RAWInput) *DeviceListener
func (*DeviceListener) Close ¶
func (l *DeviceListener) Close()
func (*DeviceListener) String ¶
func (l *DeviceListener) String() string
type FileDirInput ¶
type FileDirInput struct {
// contains filtered or unexported fields
}
func NewFileDirInput ¶
func NewFileDirInput(codec string, path string, readDepth int) *FileDirInput
func (*FileDirInput) Close ¶
func (in *FileDirInput) Close() error
type FileDirOutput ¶
type FileDirOutput struct {
// contains filtered or unexported fields
}
func NewFileDirOutput ¶
func NewFileDirOutput(codec string, path string, cf *FileDirOutputConfig) *FileDirOutput
func (*FileDirOutput) Close ¶
func (o *FileDirOutput) Close() error
type FileDirOutputConfig ¶
type FileDirOutputConfig struct { // MaxSize is the maximum size in megabytes of the log file before it gets rotated. MaxSize int `json:"maxSize"` // MaxBackups is the maximum number of old log files to retain. MaxBackups int `json:"maxBackups"` // MaxAge is the maximum number of days to retain old log files based on the // timestamp encoded in their filename. MaxAge int `json:"maxAge"` }
type GRPCOutput ¶
type GRPCOutput struct {
// contains filtered or unexported fields
}
func NewGRPCOutput ¶
func NewGRPCOutput(addr string) *GRPCOutput
func (*GRPCOutput) Close ¶
func (o *GRPCOutput) Close() error
type OutputKafkaConfig ¶
type OutputKafkaConfig struct { Host string `json:"output-kafka-host"` Topic string `json:"output-kafka-topic"` UseJSON bool `json:"output-kafka-json-format"` SASLConfig SASLKafkaConfig // contains filtered or unexported fields }
OutputKafkaConfig is the representation of kfka output configuration nolint: unused
type RAWInput ¶
RAWInput used for intercepting traffic for given address
func NewRAWInput ¶
NewRAWInput constructor for RAWInput. Accepts raw input config as arguments.
type ReinforcedReader ¶
func NewReinforcedReader ¶
func NewReinforcedReader(filepaths []string, codec protocol.Codec) *ReinforcedReader
func (*ReinforcedReader) Close ¶
func (r *ReinforcedReader) Close() error
func (*ReinforcedReader) NextFile ¶
func (r *ReinforcedReader) NextFile() error
func (*ReinforcedReader) ReadMessage ¶
func (r *ReinforcedReader) ReadMessage() (*protocol.Message, error)
type SASLKafkaConfig ¶
type SASLKafkaConfig struct { UseSASL bool `json:"input-kafka-use-sasl"` Mechanism string `json:"input-kafka-mechanism"` Username string `json:"input-kafka-username"` Password string `json:"input-kafka-password"` }
SASLKafkaConfig SASL configuration
type StdOutput ¶
type StdOutput struct {
// contains filtered or unexported fields
}
func NewStdOutput ¶
Click to show internal directories.
Click to hide internal directories.