(req *http.Request)
| 219 | } |
| 220 | |
| 221 | func (s *ProxyHandler) isLoopback(req *http.Request) (string, bool) { |
| 222 | s.outboundMux.RLock() |
| 223 | originator, found := s.outbound[req.RemoteAddr] |
| 224 | s.outboundMux.RUnlock() |
| 225 | return originator, found |
| 226 | } |
| 227 | |
| 228 | func (s *ProxyHandler) ServeHTTP(wr http.ResponseWriter, req *http.Request) { |
| 229 | if originator, isLoopback := s.isLoopback(req); isLoopback { |