3 ms·
Something to be aware of: checkip.amazonaws.com will happily return an X-Forwarded-For address https://stackoverflow.com/questions/52618096/under-what-circumsta
by madars 5y ago
Something to be aware of: checkip.amazonaws.com will happily return an X-Forwarded-For address https://stackoverflow.com/questions/52618096/under-what-circumstances-does-checkip-amazonaws-com-return-multiple-addresses https://stackoverflow.com/questions/52618096/under-what-circ...
- kortilla 5y agoUse https
- lucb1e 5y agoThat has nothing to do with an HTTP header. See for yourself: $ curl -HX-Forwarded-For:127.0.0.1 https://checkip.amazonaws.com 127.0.0.1
- gruez 5y agoI think the point is to prevent middleboxes (eg. caching proxy servers) from interfering with the request. Otherwise I don't really see the issue with the ip address being affected by X-Forwarded-For. You can just... not specify the header.
- thewakalix 5y agoHTTPS encrypts headers, thereby preventing other people from adding headers to your request. Typically people are not adding X-Forwarded-For to their own requests.
- lucb1e 5y agoI'm not arguing either point, I just pointed out that headers are independent of whether you use encryption. But now that I'm thinking about it for a sec, you might want to know what the proxy's exit IP is, and if the proxy adds an XFF Header then you just learn your own IP which wasn't what you wanted. If that is what GGGP meant.
- kortilla 5y agoHeaders don’t get injected on you unexpectedly if you encrypt.