MCPcopy Index your code
hub / github.com/tailscale/tailscale / stringifyTEI

Function stringifyTEI

wgengine/netstack/netstack.go:2144–2148  ·  view source on GitHub ↗
(tei stack.TransportEndpointID)

Source from the content-addressed store, hash-verified

2142}
2143
2144func stringifyTEI(tei stack.TransportEndpointID) string {
2145 localHostPort := net.JoinHostPort(tei.LocalAddress.String(), strconv.Itoa(int(tei.LocalPort)))
2146 remoteHostPort := net.JoinHostPort(tei.RemoteAddress.String(), strconv.Itoa(int(tei.RemotePort)))
2147 return fmt.Sprintf("%s -> %s", remoteHostPort, localHostPort)
2148}
2149
2150func ipPortOfNetstackAddr(a tcpip.Address, port uint16) (ipp netip.AddrPort, ok bool) {
2151 if addr, ok := netip.AddrFromSlice(a.AsSlice()); ok {

Callers 2

acceptTCPMethod · 0.70
acceptUDPMethod · 0.70

Calls 1

StringMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…