有代理服务器的情况下,应该是三层了吧,对你的请求是代理服务器发过来的,恐怕得通过其他方法。
Returns the Internet Protocol (IP) address of the client or last proxy that sent the request. For HTTP servlets, same as the value of the CGI variable REMOTE_ADDR. Returns:
a String containing the IP address of the client that sent the request
Returns the Internet Protocol (IP) address of the client or last proxy that sent the request. For HTTP servlets, same as the value of the CGI variable REMOTE_ADDR. Returns:
a String containing the IP address of the client that sent the request
我是想获得客户端的IP地址,检测IP的范围,以实现网站的安全。
还有没有其它的方法呢?