wood burning stoves*
The moose likes Websphere and the fly likes how does a server gets the IP address of a client Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Products » Websphere
Bookmark "how does a server gets the IP address of a client" Watch "how does a server gets the IP address of a client" New topic
Author

how does a server gets the IP address of a client

chaitanya karthikk
Ranch Hand

Joined: Sep 15, 2009
Posts: 800

hi everybody, I have a requirement.
how does the server gets the IP address or modem address or the processor number of the client. which method in java is used to get the client's IP address.

my requirement is that, if more than 3 requests come from one client to the serevr, then the sever must not provide any services for that particular client for some time. I want to get rid of denial of service attack. how to do this.

my system configurations:

operating system: windows xp.
java: 1.4
serevr: websphere application server
tool: eclipse


Love all, trust a few, do wrong to none.
James Ward
Ranch Hand

Joined: Apr 27, 2003
Posts: 263
You can do it this way inside a JSP/Servlet:



If you are talking of preventing DOS - Denial of Service Attack, there is a good write-up here:
http://qnatech.wordpress.com/2008/11/25/how-to-prevent-dos-denial-of-service-attack/


chaitanya karthikk
Ranch Hand

Joined: Sep 15, 2009
Posts: 800

thank you very much sir. i will definitely try it.
Cameron Wallace McKenzie
author and cow tipper
Saloon Keeper

Joined: Aug 26, 2006
Posts: 4968
    
    1

DOS is a pretty significant topic. I'd suggest two things:

1. Look online for DOS attack solutions that have proven to work. You might save alot of time by leveraging code and techniques by some of the industry experts.

2. If you do invent a great DOS solution, patent it outside of your company and make millions for yourself.

Good luck!

-Cameron McKenzie
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how does a server gets the IP address of a client
 
Similar Threads
How to get Mac Id of my client machine
Read Client IP Address behind Proxy
RMI Server
getting client IP address
Send real time unix system logging to a remote db server ?