core

package
v0.0.0-...-f0ba5e8 Latest Latest
Warning

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

Go to latest
Published: Feb 18, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var SocketFunctions []SocketFunction = []SocketFunction{
	{
		// contains filtered or unexported fields
	},
	{
		// contains filtered or unexported fields
	},
	{
		// contains filtered or unexported fields
	},
	{
		// contains filtered or unexported fields
	},
}

Functions

func GetSocks

func GetSocks() []netstat.SockTabEntry

GetSocks returns all type socket`s port information

func SortByPorts

func SortByPorts()

Sort sockets by Port number

Types

type ByPort

type ByPort []netstat.SockTabEntry

func (ByPort) Len

func (a ByPort) Len() int

func (ByPort) Less

func (a ByPort) Less(i, j int) bool

func (ByPort) Swap

func (a ByPort) Swap(i, j int)

type Socket

type Socket struct {
	Port        int
	ProcessID   int
	ProcessName string
	SocketType  string
}

func FilterSocks

func FilterSocks(socks []Socket, startPort, endPort int) []Socket

FilterSocks filters sockets by start and end ports

func Format

func Format(socks []netstat.SockTabEntry) []Socket

Format formats netstat type to UI type

type SocketFunction

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

Jump to

Keyboard shortcuts

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