pdns-protobuf-logger

module
v0.0.0-...-6ae2a7f Latest Latest
Warning

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

Go to latest
Published: Feb 27, 2024 License: AGPL-3.0

README

pdns-protobuf-logger

Go

pdns-protobuf-logger is a powerDNS(recursor, authoritative, dnsdist) that logs DNS protobuf messages to rotating compressed jsonl log files.

  • Authoritative DNS message logging
  • Query response logging
  • Configurable logging parameters such as filename prefix, log directory, maximum lines per log file, and log rotation time

Usage

The main functionality of the project is encapsulated in the cmd/pdnslogger.go file. This file sets up the logging configurations and handles incoming connections.

// Initialize the logger configurations
AuthoritativeConfig := writer.LoggerConfig{
    FilenamePrefix: "authoritative",
    LogDir:         "./logs",
    MaxLines:       100000,
    RotationTime:   600 * time.Second,
}

QueryResponseConfig := writer.LoggerConfig{
    FilenamePrefix: "queryresponse",
    LogDir:         "./logs",
    MaxLines:       100000,
    RotationTime:   600 * time.Second,
}

Installation

git clone https://github.com/clwg/pdns-protobuf-logger.git
cd pdns-protobuf-logger
go build

Contributing

Contributions are welcome. Please submit a pull request or create an issue to discuss the changes you want to make.

License

This project is licensed under the GNU Affero General Public License v3.0.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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