Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/ericls/imgdd
/ ExtractIPDirect
Function
ExtractIPDirect
httpserver/ip.go:9–12 ·
view source on GitHub ↗
(req *http.Request)
Source
from the content-addressed store, hash-verified
7
)
8
9
func
ExtractIPDirect(req *http.Request) string {
10
h, _, _ := net.SplitHostPort(req.RemoteAddr)
11
return
h
12
}
13
14
func
ExtractIPXFF(req *http.Request) string {
15
xffIps := req.Header[
"X-Forwarded-For"
]
Callers
1
ExtractIP
Function · 0.85
Calls
no outgoing calls
Tested by
no test coverage detected