Created
November 21, 2014 19:18
-
-
Save steventen/e9a4fb3380e4ca4002e8 to your computer and use it in GitHub Desktop.
Get request info
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| proxy.OnRequest().DoFunc(func(req *http.Request, ctx *goproxy.ProxyCtx) (*http.Request, *http.Response) { | |
| logger.Printf("Request: %s | IP: %s", req.URL, req.RemoteAddr) | |
| return req, nil | |
| }) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment