File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Servlets and the fly likes how to find user ip address and system details in java Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "how to find user ip address and system details in java" Watch "how to find user ip address and system details in java" New topic
Author

how to find user ip address and system details in java

sunil soni
Greenhorn

Joined: Nov 16, 2010
Posts: 7

I want to find user ip address and system detail .I am working on struts 1.3 and want to collect data for reporting purpose .
please help.

Thanks in advance.


Sunil
Piyush Joshi
Ranch Hand

Joined: Jun 10, 2011
Posts: 207

For client's IP address: See this post
For client's system details: you can get HTTP request header "user-agent" which contains information like browser-details, operating system etc.


Piyush
Akhilesh Trivedi
Ranch Hand

Joined: Jun 22, 2005
Posts: 1526
Did you try writing a javascript code? I think it should be possible to get details and pass them off bundling in hidden fields.

But yes, for ip-address thing, javascript too may depend on some server side script.


Keep Smiling Always — My life is smoother when running silent. -paul
[FAQs] [Certification Guides] [The Linux Documentation Project]
udaykiran pulipati
Greenhorn

Joined: Dec 21, 2012
Posts: 12

Here is the code for get ipaddress and system details using Java.



UdayKiran Pulipati
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41629
    
  55
Aside from the fact that the question was asked more than 2 years ago, it specifically asked about the client IP address in the context of a web app, something entirely different from what this code does.


Ping & DNS - my free Android networking tools app
 
Don't get me started about those stupid light bulbs.
 
subject: how to find user ip address and system details in java