Results 1 to 2 of 2
  1. #1
    R O C K Y's Avatar
    R O C K Y is offline Member
    Join Date
    Feb 2009
    Posts
    19
    Rep Power
    0

    Question Problem of getting erroneous IP address

    I am facing the Problem of getting erroneous IP address 127.0.0.1 instead of my own IP address by using the following code:-

    public void doFilter(ServletRequest request, ServletResponse response,
    FilterChain chain) throws IOException,
    {


    String ip = request.getRemoteAddr();

    /.....
    }
    if it comes with the IP add of localhost, then in that case need to know y it happens.........

    can nyone tell me...........:o

  2. #2
    Join Date
    Jan 2009
    Location
    Delhi
    Posts
    8
    Rep Power
    0

    Default

    For servers with more than one IP address, this attribute
    specifies which address will be used for listening on the specified
    port. By default, this port will be used on all IP addresses
    associated with the server. A value of <code>127.0.0.1</code>
    indicates that the Connector will only listen on the loopback
    interface.

Similar Threads

  1. Client IP Address
    By goodjonx in forum Networking
    Replies: 3
    Last Post: 09-23-2009, 11:27 AM
  2. Address bar not visible
    By Akashchopra521 in forum New To Java
    Replies: 0
    Last Post: 12-03-2008, 08:13 AM
  3. Looking Up the Address of a Host
    By Java Tip in forum java.net
    Replies: 0
    Last Post: 04-07-2008, 09:11 PM
  4. JSP getting IP address
    By Java Tip in forum Java Tip
    Replies: 0
    Last Post: 01-29-2008, 10:05 AM
  5. I am not able to print Address
    By Albert in forum New To Java
    Replies: 1
    Last Post: 07-13-2007, 04:37 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •