MCPcopy Create free account
hub / github.com/ContentSquare/chproxy / extractFirstMatchFromIPList

Function extractFirstMatchFromIPList

proxy_handler.go:73–83  ·  view source on GitHub ↗
(ipList string)

Source from the content-addressed store, hash-verified

71}
72
73func extractFirstMatchFromIPList(ipList string) string {
74 if ipList == "" {
75 return ""
76 }
77 s := strings.Index(ipList, ",")
78 if s == -1 {
79 s = len(ipList)
80 }
81
82 return ipList[:s]
83}
84
85func parseForwardedHeader(fwd string) string {
86 splits := strings.Split(fwd, ";")

Callers 1

parseDefaultProxyHeadersFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected