globals.asa problems in iis6.

From: Mike McGrath (
Date: 12/03/03

Date: Wed, 3 Dec 2003 09:41:18 -0800

We are currently attempting to get our product to work on windows 2003. We write a web based product that uses an ISAPI filter, some ISAPI extensions and some ASP pages. We are running into a problem were on the first request to the asp layer we get an error initializing one of our objects in globals.asa. There are 2 session level objects that are created in globals.asa. The first object gets creaed fine, but the second one returns a 8002801d error. The constructor for the second object never gets called. All documentation on this error says that it is a permissions issue with loading the com dll, but both of these objects are implimented by the same com dll. Regmon and Filemon show no errors at all. All subsequent requests work as expected.
In the process of tracking this down, I was attempting to look at the thread token to dump out the user sid that we were running as at the time of the error in the first objects constructor. At this point I stumbled across some interesting information. On the first request the current thread gets access denied trying to look at the thread token. On subsequent requests, the thread token is accessible and is running as the anonymous user. I am not sure if this is directly related to the problems that I am seeing, but these 2 requests appear to be executing as different users.
Does anyone have any ideas here? It looks like a windows bug to me, since the initial request is running under a different user context.