943,816 Members | Top Members by Rank

Ad:
  • C++ Discussion Thread
  • Unsolved
  • Views: 724
  • C++ RSS
Oct 14th, 2008
0

Read incoming packets

Expand Post »
Hello,
I need help in my project, where I want to catch, read and forward some packets given to another application. Example: some packets is incoming for application MyApp on port 888. The another application is running on background and listening for communication with MyApp. If the server sends packet I need to catch it before it comes to MyApp and if data inside will include some special code, like "....server_echo" I need to destroy it. But if there isn't any special code, I need to forward it to MyApp.
It looks like a firewall application.
Thank you
Similar Threads
Reputation Points: 10
Solved Threads: 0
Junior Poster in Training
Thew is offline Offline
61 posts
since Jan 2008
Oct 14th, 2008
0

Re: Read incoming packets

Set your app to listen to 127.0.0.1:888
Your filter then connects to 127.0.0.1:888 and itself listens on port 888 of the machine itself.
Your filter now sees all the traffic on that port, and can forward/modify/drop as necessary.
Team Colleague
Reputation Points: 5862
Solved Threads: 950
Posting Sage
Salem is offline Offline
7,164 posts
since Dec 2005

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in C++ Forum Timeline: OpenGL in C++
Next Thread in C++ Forum Timeline: date and time formats





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC