Solved

Applet and trace route

Posted on 2002-04-05
5
227 Views
Last Modified: 2010-03-31
I have a Java applet running in a Web page.  If possible, I need to determine from within the applet the trace route that the user took to reach the Web site.

Further, it would be acceptable if I could just get the IP address of the client machine on which the applet is running.

I understand that applet security is likley to prevent this but any help would be appreciated.
0
Comment
Question by:llewelm
  • 3
  • 2
5 Comments
 
LVL 18

Expert Comment

by:bobbit31
ID: 6921042
have you tried InetAddress.getLocalHost().getHostAddress()?
0
 
LVL 1

Author Comment

by:llewelm
ID: 6921063
Yes.  This returns "127.0.0.1", the "localhost" address.  I need the actual IP address.
0
 
LVL 18

Accepted Solution

by:
bobbit31 earned 200 total points
ID: 6921756
0
 
LVL 18

Expert Comment

by:bobbit31
ID: 6921768
also, can you use serverside scripting (cgi/servlets)?

if so, then you can have your applet get the traceroute from there.
0
 
LVL 1

Author Comment

by:llewelm
ID: 6925100
This was exactly what I needed.  Thanks.
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

For customizing the look of your lightweight component and making it look lucid like it was made of glass. Or: how to make your component more Apple-ish ;) This tip assumes your component to be of rectangular shape and completely opaque. (COD…
By the end of 1980s, object oriented programming using languages like C++, Simula69 and ObjectPascal gained momentum. It looked like programmers finally found the perfect language. C++ successfully combined the object oriented principles of Simula w…
Viewers learn about the scanner class in this video and are introduced to receiving user input for their programs. Additionally, objects, conditional statements, and loops are used to help reinforce the concepts. Introduce Scanner class: Importing…
Viewers will learn one way to get user input in Java. Introduce the Scanner object: Declare the variable that stores the user input: An example prompting the user for input: Methods you need to invoke in order to properly get  user input:

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question