How to debug the code in FilterInit()?? (Full Version)

All Forums >> [ISA Server 2004 Misc.] >> ISA Server 2004 Programming



Message


liuyuanxun_1983 -> How to debug the code in FilterInit()?? (1.Sep.2005 10:32:00 PM)

The FilterInit() will be called immediatly the firewall starts. Only after the firewall started could we debug the filter. But who can tell me how I can debug the code in FilterInit()?




JesseA -> RE: How to debug the code in FilterInit()?? (2.Sep.2005 4:52:00 AM)

Most simple way that I see is to insert "Sleep(10000);" at the beginning of FilterInit function. After firewall service start quickly attach debugger and set breakpoint to next line after Sleep function.
Inserting DebugBreak (int 3) will not work in this function, in this case firewall service will just crash (AFAIK).




tech89 -> RE: How to debug the code in FilterInit()?? (7.Oct.2005 4:21:00 PM)

I have also put an assert(0); into the code just before my breakpoint. When the firewall throws the assert, attach your debugger then hit the Continue button on the assert dialog.




el_akchurin -> RE: How to debug the code in FilterInit()?? (27.Oct.2005 11:30:00 AM)

quote:
Originally posted by yuanxun liu:
The FilterInit() will be called immediatly the firewall starts. Only after the firewall started could we debug the filter. But who can tell me how I can debug the code in FilterInit()?

If you have such a problem: SCM terminates service before you can attach to it, you have to set some additional parameters for service in registry. See "Debug services" in MSDN.




Page: [1]