comm

package
v0.0.0-...-d4fbfd5 Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2024 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddRoute

func AddRoute(tunAddr string, tunGw string, tunMask string)

func CheckTcp

func CheckTcp(host string, port string) bool

func CmdHide

func CmdHide(name string, arg ...string) *exec.Cmd

func ExistStdOutput

func ExistStdOutput() bool

func GenPasswordHead

func GenPasswordHead(password string) string

func GetFreePort

func GetFreePort() (string, error)

func GetFreeUdpPort

func GetFreeUdpPort() (string, error)

func GetGateway

func GetGateway() string

func GetNetworkInfo

func GetNetworkInfo() ([]lAddr, error)

func InitLog

func InitLog(_logfile string, flag int)

func Tail

func Tail(name string, cutLine int) string

func UdpNatDecode

func UdpNatDecode(data []byte) (*net.UDPAddr, *net.UDPAddr, error)

nat src dst

func UdpNatEncode

func UdpNatEncode(src *net.UDPAddr, dst *net.UDPAddr) []byte

nat src dst

func UniqueId

func UniqueId(_len int) string

生成Guid字串

Types

type CommConn

type CommConn interface {
	SetDeadline(t time.Time) error
	io.ReadWriteCloser
}

type HttpConn

type HttpConn struct {
	W  io.Writer
	Wf http.Flusher
	R  io.ReadCloser
}

func (HttpConn) Close

func (conn HttpConn) Close() error

func (HttpConn) Read

func (conn HttpConn) Read(buf []byte) (int, error)

func (HttpConn) SetDeadline

func (conn HttpConn) SetDeadline(t time.Time) error

func (HttpConn) Write

func (conn HttpConn) Write(buf []byte) (int, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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