drop

package module
v0.0.0-...-bee5ec2 Latest Latest
Warning

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

Go to latest
Published: Dec 30, 2019 License: Apache-2.0 Imports: 10 Imported by: 0

README

example

Name

drop - can be used to drop specified DNS query types e.g. AAAA, returning 'NOTIMP' as rcode.

Description

This plugins drop DNS requests of specific types

Syntax

drop AAAA

Metrics

If monitoring is enabled (via the prometheus directive) the following metric is exported:

  • coredns_drop_request_count_total{server} - query count to the drop plugin.

The server label indicated which server handled the request, see the metrics plugin for details.

Ready

This plugin reports readiness to the ready plugin. It will be immediately ready.

Examples

In this configuration, all queries for *.example.com will be dropped

example.com {
  drop AAAA
}

Also See

See the manual.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Drop

type Drop struct {
	Next plugin.Handler
	// contains filtered or unexported fields
}

Drop struct

func (Drop) Name

func (d Drop) Name() string

Name implements the Handler interface.

func (Drop) Ready

func (e Drop) Ready() bool

Ready implements the ready.Readiness interface, once this flips to true CoreDNS assumes this plugin is ready for queries; it is not checked again.

func (Drop) ServeDNS

func (d Drop) ServeDNS(ctx context.Context, w dns.ResponseWriter, r *dns.Msg) (int, error)

ServeDNS implements the plugin.Handler interface. This method gets called when drop is used in a Server.

Jump to

Keyboard shortcuts

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