cut

package
v1.7.0 Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2024 License: BSD-3-Clause Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Cut = &charm.Spec{
	Name:  "cut",
	Usage: "cut [options] slice [ slice slice ... ]",
	Short: "extract a pcap using index slices",
	Long: `
The cut command produces an output pcap from an input pcap by selecting
the indicated packets from the input.  The input format is unmodified as
the output is created by simply extracting verbatim the relevant ranges of
the input pcap.

Each selected slice is expressed as
an index or index range, e.g., "10" is the packet 10 in the input (starting from 0),
"3:5" is packets 3 and 4, "8:5" is packets 8, 7, and 6, and so forth.

For pcap-ng input, the cuts are applied to each section.

This command isn't all that useful in practice but is nice for creating
test inputs for the slice and index commands.
`,
	New: New,
}

Functions

func New

func New(parent charm.Command, f *flag.FlagSet) (charm.Command, error)

Types

type Command

type Command struct {
	*root.Command
	// contains filtered or unexported fields
}

func (*Command) Run added in v0.0.3

func (c *Command) Run(args []string) error

Jump to

Keyboard shortcuts

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