dhcp6test

package
v0.0.0-...-2a67805 Latest Latest
Warning

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

Go to latest
Published: Mar 11, 2019 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Package dhcp6test provides utilities for testing DHCPv6 clients and servers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Recorder

type Recorder struct {
	MessageType   dhcp6.MessageType
	TransactionID [3]byte
	OptionsMap    dhcp6.Options
	Packet        *dhcp6.Packet
}

Recorder is a dhcp6.ResponseSender which captures a response's message type and options, for inspection during tests.

func NewRecorder

func NewRecorder(txID [3]byte) *Recorder

NewRecorder creates a new Recorder which uses the input transaction ID.

func (*Recorder) Options

func (r *Recorder) Options() dhcp6.Options

Options returns the Options map of a Recorder.

func (*Recorder) Send

func (r *Recorder) Send(mt dhcp6.MessageType) (int, error)

Send creates a new DHCPv6 packet using the input message type, and stores it for later inspection.

Jump to

Keyboard shortcuts

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