• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

How to refuse connection at server using sniffers

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,
I have written a web server that listens to a particular port e.g. 25000. I want to implement a concept that the request which is coming from the client should be refused in case it contains invalid data. For example, if the web server listens to the port and the client sends a request to the port with some data that is not supposed to be met by the server, a sniffer class should detect the invalidity of the request and refuse connection to the server.
The issues in this case are:
1. The validity of the request could be verified after the server accepts the request but in this case as soon as the server accepts the request, a connection object is returned to the client. The requirement is that if the data is not valid, a connection object should not be returned to the client as it is improper to accept the request and then reject the connection.
2. The validity of the data from the client can be verified at the client itself, but in this case there will be not network communication.

Please suggest me how to write a sniffer that stands in between the client and the server and sniffs the data from the client.
Thanks in advance,
Aniruddha
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic