package
0.8.9
Repository: https://github.com/influx6/npkg.git
Documentation: pkg.go.dev

# Functions

ConnToHTTP proxies a requests from a net.Conn to a destination request, writing the response to provided ResponseWriter.
CopyUDPAddr returns a new copy of a giving UDPAddr.
FreePort returns a random free port from the underline system for use in a network socket.
GetAddr takes the giving address string and if it has no ip or use the zeroth ip format, then modifies the ip with the current systems ip.
GetClustersFriends returns a giving set of routes from the provided port number.
GetExternalIP returns the actual internal external IP of the calling system.
GetInterfaceIPs returns the list of IP of the giving interfaces found in the system.
GetMainIP returns the giving system IP by attempting to connect to a imaginary ip and returns the giving system ip.
GetMainIPByInterface returns the giving ip of the current system by looping through all interfaces returning the first ipv4 found that is not on the loopback interface.
GetURLIP returns a giving ip addres if the ip string is not an ip address.
HTTPToConn proxies a src Request to a net.Con connection and writes back the response to the src Response.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
IsIPInList returns true/false if the giving ip list were equal.
No description provided by the author
No description provided by the author
LoadTLS loads a tls.Config from a key and cert file path.
MakeListener returns a new net.Listener requests.
NewConn returns a tls.Conn object from the provided parameters.
NewHTTPServer returns a new http.Server using the provided listener.
NewKeepAliveListener returns a new net.Listener from underline net.TCPListener where produced net.Conns respect keep alive regulations.
NewTimedConn returns a new instance of a TimedConn.
No description provided by the author
ProxyHTTPRequest copies a http request from a src net.Conn connection to a destination net.Conn.
ResolveAddr returns an appropriate address by validating the presence of the ip and port, if non is found, it uses the default 0.0.0.0 address and assigns a port if non is found.
TCPListener returns a new net.Listener requests.
TLSCipher returns a cipher string version based on the supplied hex value.
TLSConn returns a tls.Conn object from the provided parameters.
TLSFromConn returns a new tls.Conn using the address and the certicates from the provided *tls.Conn.
TLSVersion returns a string version number based on the tls version int.
UpgradeConnToTLS upgrades the giving tcp connection to use a tls based connection encrypted by the giving tls.Config.

# Structs

No description provided by the author
No description provided by the author
DudLocationService returns a default unknown location with provided address as ip.
No description provided by the author
No description provided by the author
TimedConn implements a wrapper around a net.Conn which guards giving connection with appropriate read/write timeout.

# Interfaces

No description provided by the author

# Type aliases

No description provided by the author