seqtracker

package
v0.2.4 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2025 License: ISC Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Tracker

type Tracker struct {
	// contains filtered or unexported fields
}

Tracker tracks uint32 sequence numbers inside a 16-packet wide window.

Assumes tracking starts at zero. On overflow, any sequence number < MaxUint32/2 will be accepted to reset.

An empty sequence tracker is ready for use.

func (*Tracker) MayAccept

func (st *Tracker) MayAccept(s uint32) (accept bool)

MayAccept returns true if the packet with sequence number s should be accepted. This advances the state of the sequence tracker.

Jump to

Keyboard shortcuts

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