Re: Notification for open/closed TCP/UDP Connection



If you want the title of the main window ( that I appreciate you mean by
"actual name of the application" ) you need to enumerate parent ( top )
windows and use
GetWindowModuleFileName() to compare
Arkady

"Manish" <Manish@xxxxxxxxxxxxxxxxx> wrote in message
news:Oum7Y0OmGHA.2056@xxxxxxxxxxxxxxxxxxxxxxx
Hi Arkady,

Thanks a lot for your suggestions. Actually it is very time critical
application. So, it will be good for me to get the notification. And the
second thing is using netstatp, i can get only process name. In that case,
if i change the name of the executable it will reflect the changed name in
netstatp. But, i want actual name of the application.

As example if someone change the name of "internet explorer" to "ie", in
netstap i will get the name "ie" but i want to know the actual name which
is "internet explorer".

Thanks again for your valuable time.

Thanks & Regards,

Manish
Arkady Frenkel wrote:
Additionally, to find processes , you can use netstatp from
http://www.sysinternals.com/utilities/tcpview.html

Arkady

"Arkady Frenkel" <arkadyf@xxxxxxxxxxxxxxxx> wrote in message
news:eR0RK8slGHA.4244@xxxxxxxxxxxxxxxxxxxxxxx
I don't know notifications of such kind , but you can use polling of TCP
table ( GetTcpTable() ) e.g.
Arkady

"Manish" <Manish@xxxxxxxxxxxxxxxxx> wrote in message
news:%23OqIOyplGHA.4864@xxxxxxxxxxxxxxxxxxxxxxx
I am writing one program using VS2005, C++. I am using winsock library
and iphelper library.



The problem I am facing is: I want notification in my program when any
application opens or closes TCP/UDP connections. And with that
notification I want to get the information about the application
(particularly application name) which has opened/closed the ports and
port number.



I have gone through the MSDN and also, searched on the net. But I was
not able to find any message or callback function which I can register
with OS to get such notification.



Then I came across the windows firewall documentation. And I found that
windows firewall uses such notification scheme to get informed about
the open and closed port with application information.



So, can you guide me how to get such notifications?



I am using windows xp sp2.



.



Relevant Pages

  • Re: Desktop Still Crashing
    ... the place, the taskbar jumping up to the side, which I hate.. ... Classic Theme and Notification Area: ... If you are using the Windows Classic theme in Windows XP, ... >> To restart Explorer, Not sure why I needed to restart Explorer, not ...
    (microsoft.public.windowsxp.basics)
  • Re: inter process communication
    ... a notification that it's ... Windows messaging system for the application. ... communicate with this separate process. ... CreateProcessAPI which is invoked from the managed app. ...
    (microsoft.public.windowsce.embedded.vc)
  • Re: Swing Komponenten durch den Anwender editiert
    ... Wir pflegen/erweitern eine bestehende Swing Rich Client ... Heute sehr schön zu sehen in Frameworks wie Eclipse. ... globaler Notification Manager, den Windows benachrichtigen ... Emitter und Listener bei einem globalen Notification Manager ...
    (de.comp.lang.java)
  • Re: USB unplug notification
    ... under Windows CE message will not appear here! ... can always get the USB notification when the device is plugged in. ... that notification only when I CLOSE the serial port. ... Copy this definition before the message map of the cpp file. ...
    (microsoft.public.windowsce.embedded)
  • Re: USB unplug notification
    ... The reason why you can receive notification from OS is driver info OS the ... If you look at driver. ... there seems to be NO hardware cable detection in COM port by ... under Windows CE message will not appear here! ...
    (microsoft.public.windowsce.embedded)