|
Prev: How pwi file can be read and converted to string in vb.net
Next: Stop a process and Windows media control
From: ifaenson on 1 Feb 2005 11:00 Dear gurus, We're running the passthru-type winsock Layered Service Provider based on the Platform Builder 4.2 sample code on an iPAQ of the recent vintage. Two Pocket PC (as opposed to vanilla WinCE 4.2) changes Microsoft recommended have indeed been applied to the code. When the LSP is installed on the fly (through the INST_LSP program supplied in the Platform Builder), very few applications load and use the LSP DLL. ActiveSync is among them, however, if started after the LSP install. Internet Explorer is not, even if started afterwards. The device.exe and services.exe are not either which is understandable due to the very helpful blog by Igor Dvorkin, thanks a lot: http://blogs.msdn.com/cenet/archive/2004/12/07/277890.aspx Ok, when the install code is transferred to the DllRegisterServer() export within the DLL itself and the WS2 Registry is configured appropriately, the device.exe and services.exe do in fact start loading and using the LSP DLL upon the soft restart. Moreover, some of the other apps like the platform manager (cemgrc.exe), process viewer (cepwcli.exe), VC++ Spy (cespycli.exe) load and use the LSP as well. However, most applications like ActiveSync and Internet Explorer do not. What might be the reason? The LSP needs to observe all the sockets, not just some. I see that the ssllsp.dll is in fact loaded and used by virtually all relevant apps. What does it do differently? The LSP of mine is installing itself over all base providers for the time being, just like the sample code. The DllRegisterServer() reports no install issues anywhere, and the run-time trace seems reasonable when the DLL is used. The DllRegisterServer() returns S_OK, just like the real server registration. Should I start playing with the WSAPROTOCOL_INFOW members? Many thanks for your insights, Ilya Faenson Rockville, MD USA ifaenson(a)hotmail.com
From: Ajay Agrawal on 3 Feb 2005 00:54 When you install LSP using DllRegisterServer() during boot time, order of LSP installation can not be controlled on CE 4.2. In this case almost always SSL LSP will be installed on the top in the catalog and will be used by all the APPs like IE etc. As SSL LSP is installed over Base providers so your LSP will never be called. You can check the order of your LSP in the catalog using WSCEnumProtocols(). When you install LSP on-the-fly then any application which has started before that will not use your lsp. -Ajay <ifaenson(a)hotmail.com> wrote in message news:1107273646.520405.305250(a)z14g2000cwz.googlegroups.com... > Dear gurus, > > We're running the passthru-type winsock Layered Service Provider > based on the Platform Builder 4.2 sample code on an iPAQ of the > recent vintage. Two Pocket PC (as opposed to vanilla WinCE 4.2) > changes Microsoft recommended have indeed been applied to the code. > When the LSP is installed on the fly (through the INST_LSP program > supplied in the Platform Builder), very few applications load and > use the LSP DLL. ActiveSync is among them, however, if started > after the LSP install. Internet Explorer is not, even if started > afterwards. The device.exe and services.exe are not either which > is understandable due to the very helpful blog by Igor Dvorkin, > thanks a lot: > > http://blogs.msdn.com/cenet/archive/2004/12/07/277890.aspx > > Ok, when the install code is transferred to the DllRegisterServer() > export within the DLL itself and the WS2 Registry is configured > appropriately, the device.exe and services.exe do in fact start > loading and using the LSP DLL upon the soft restart. Moreover, > some of the other apps like the platform manager (cemgrc.exe), > process viewer (cepwcli.exe), VC++ Spy (cespycli.exe) load and > use the LSP as well. However, most applications like ActiveSync > and Internet Explorer do not. What might be the reason? The LSP > needs to observe all the sockets, not just some. > > I see that the ssllsp.dll is in fact loaded and used by virtually > all relevant apps. What does it do differently? The LSP of mine > is installing itself over all base providers for the time being, > just like the sample code. The DllRegisterServer() reports no > install issues anywhere, and the run-time trace seems reasonable > when the DLL is used. The DllRegisterServer() returns S_OK, just > like the real server registration. Should I start playing with > the WSAPROTOCOL_INFOW members? > > Many thanks for your insights, > Ilya Faenson > Rockville, MD USA > ifaenson(a)hotmail.com >
From: ifaenson on 4 Feb 2005 18:32 Ajay, Thank you for your response. One could actually control the order of LSPs in CE 4.2 some, but that was not an issue here. Virtually nothing TCP/IP related worked when I installed my LSP on the top. I've worked around the real issue with the help from Microsoft, and we will hopefully hear from them shortly in this respect. Meanwhile, all processes, including the IE, now happen to load the LSP of mine. The genuine traffic from many applications now passes through the LSP - all ActiveSync related, performance tools, ftp client etc. However, I only see very few calls coming in from the IE, primarily those infamous failing WSPStringToAddress() calls passing in URLs as opposed to IP addresses which have been discussed here before. I observe no sends or receives. I've not tried browsing to secure sites, so no SSL should be in the picture whatsoever. Who could be hiding the IE data? I can see it in the NDIS intermediate driver of mine, so it is certainly around. :-) Many thanks for your insights, Ilya Faenson Rockville, MD USA ifaenson(a)hotmail.com
From: ganesan.nagrajan on 7 Feb 2005 16:28 Sorry to interrupt here. Since you guys are discussing the LSP for windows CE., i would like to ask a question if you don't mind. I tried to use the Sample that came with platform builder 4.2 . I get error(NULL) in the following function in the WSPStartup() funtcion. Bascially Overlapped Reuqest failed. lpWPUCompleteOverlappedRequest = (LPWPUCOMPLETEOVERLAPPEDREQUEST) GetProcAddress (hWS2_32, _T("WPUCompleteOverlappedRequest")); If you guys don't mind could you please let me know why? Thanks very much Ganesan
From: ganesan.nagrajan on 10 Feb 2005 22:30
First of all I am sorry for "Mr. ifaen...(a)hotmail.com" since I seem to have interrupted posting flow. I didn't know I am not suppose to ask a question in between. I hope he gets his help. Thanks much for the answer. I Did that before posting this message. It went thru and was able to see Infrared traffic but it Hung when I craddled the device (Probably WAN packets couldn't go thru) and I did NOT see any internet packets Probably its the loading order you guys are discussing here (or) Mr. ifaen... knows how to tackle this issue. Thanks again Ganesan |