WindowsXP-SP1/inetsrv/iis/svcs/dbgext
Microsoft f7ca35dddd First commit 2020-09-30 16:53:49 +02:00
..
oplock First commit 2020-09-30 16:53:49 +02:00
cvinfo.h First commit 2020-09-30 16:53:49 +02:00
dbgasp.cxx First commit 2020-09-30 16:53:49 +02:00
dbgatq.cxx First commit 2020-09-30 16:53:49 +02:00
dbgcc.cxx First commit 2020-09-30 16:53:49 +02:00
dbgcc.hxx First commit 2020-09-30 16:53:49 +02:00
dbginet.cxx First commit 2020-09-30 16:53:49 +02:00
dbglkrh.cxx First commit 2020-09-30 16:53:49 +02:00
dbglocks.cxx First commit 2020-09-30 16:53:49 +02:00
dbgthunk.cxx First commit 2020-09-30 16:53:49 +02:00
dbgtrace.cxx First commit 2020-09-30 16:53:49 +02:00
dbgwmif.cxx First commit 2020-09-30 16:53:49 +02:00
dbgwreq.cxx First commit 2020-09-30 16:53:49 +02:00
dbgwxin.cxx First commit 2020-09-30 16:53:49 +02:00
dumpoff.cxx First commit 2020-09-30 16:53:49 +02:00
enumheap.cxx First commit 2020-09-30 16:53:49 +02:00
enummod.cxx First commit 2020-09-30 16:53:49 +02:00
exec.cxx First commit 2020-09-30 16:53:49 +02:00
fcache.cxx First commit 2020-09-30 16:53:49 +02:00
findmod.cxx First commit 2020-09-30 16:53:49 +02:00
heapfind.cxx First commit 2020-09-30 16:53:49 +02:00
heapstat.cxx First commit 2020-09-30 16:53:49 +02:00
help.cxx First commit 2020-09-30 16:53:49 +02:00
inetdbg.def First commit 2020-09-30 16:53:49 +02:00
inetdbg.rc First commit 2020-09-30 16:53:49 +02:00
inetdbgp.h First commit 2020-09-30 16:53:49 +02:00
makefile First commit 2020-09-30 16:53:49 +02:00
mod.cxx First commit 2020-09-30 16:53:49 +02:00
ntstuff.cxx First commit 2020-09-30 16:53:49 +02:00
oemdbi.h First commit 2020-09-30 16:53:49 +02:00
readme.txt First commit 2020-09-30 16:53:49 +02:00
ref.cxx First commit 2020-09-30 16:53:49 +02:00
sources First commit 2020-09-30 16:53:49 +02:00
spud.cxx First commit 2020-09-30 16:53:49 +02:00
strlog.cxx First commit 2020-09-30 16:53:49 +02:00
template.cxx First commit 2020-09-30 16:53:49 +02:00
ver.cxx First commit 2020-09-30 16:53:49 +02:00
vm.cxx First commit 2020-09-30 16:53:49 +02:00

readme.txt

README.txt

Author:         Murali R. Krishnan      (MuraliK)
Created:        Aug 27, 1997

Revisions:
    Date            By               Comments
-----------------  --------   -------------------------------------------


Summary :
 This file describes the files in the directory iis\svcs\infocomm\dbgext\
     and details related to IIS Debugger Extensions for NTSD.


File            Description

README.txt      This file.

dbgatq.cxx      ATQ (Async Thread Queue) module related debugging helper code
dbgcc.cxx       w3svc: CLIENT_CONN & HTTP_REQUEST related debugging helper code
dbginet.cxx     ISATQ objects general helper code - 
                        Allocation Cache, Scheduler ..
dbgthunk.cxx    Generic & Thunk code for the NTSD extension to function
                        inside the Debugger process

dbgwmif.cxx     Debugger extension for WAM INFO objects in w3svc.dll
dbgwreq.cxx     Debugger extensions for WAM_REQUEST object in w3svc.dll
dbgwxin.cxx     Debugger extensions for WAM_EXEC_INFO object in wam.dll

enummod.cxx     Enumerate module information - enum func.
mod.cxx         Used to enumerate loaded modules in the process
ref.cxx         Debugger extension for use with IIS RefTraceLogs 
ver.cxx         Version information for loaded modules

inetdbg.def     Def file for the dll
inetdbg.rc      Resources for the dll
inetdbgp.h      Precompiled header file for the DLL

makefile                NT Build related files
makefile.inc
sources



Implementation Details

Contents:
1) Debugger & Debuggee
2) Use of Thunks
3) private/public data members
*) Acknowledgements


1) Debugger & Debuggee
-----------------------
 NTSD is the system debugger for NT. We use it to do console mode debugging
for NT processes. In this context the debugger process is the master process
that runs the program in a separate process (debuggee). NTSD & CDB function
as the debugger process here. The underlying process is called the debuggee
process. The NTSD extension is loaded into the debugger process to help
us debug the debuggee. From the extensions insided the debugger, we can
only access the data blocks in the debugee process. This means that we cannot
be calling member functions or other fancy operations inside the debuggee
code. 

2) Use of Thunks
----------------
 When a project involves C++ headers, invariably one finds inline member
functions that show up in the header. Such functions have underlying code
implemented in one of the dlls of the debuggee. But these are not accessible
within the debugger process. To compile the debugger extensions the compiler
looks to resolve such inlined functions. There are two ways to resolve this:
a) link to the dlls of the debuggee process => redundantly code will be loaded
in the debuggee process (sometimes this may lead to failure, especially if
the debuggee dll does complicated initializations)
b) use dumb thunks - code that does nothing as a substitute for the original
functions. Given that we do not really care exercising the member functions,
thunks serve as the best approach.

In this current inetdbg.dll, the thunks are defined in dbgthunk.cxx.

3) Private/Public members
-------------------------
 C++ permits good abstraction and encapsulation using private, public, and
protected keywords to mask direct access to data members if needed. Inside
the debugger process, we can only access data. So to print out members
we may have to reach inside C++ structures and classes and pull out data 
members. To ease this it is good to # define the private & protected keywords
to be 'public' itself. This does no harm, because we are not really doing any
real work inside the debugger extensions that can affect state of the 
object.


*) Acknowledgements
-------------------
I would like to thank Keith Moore (KeithMo) for techniques and technical
consultation on this debugger extension dll. JohnL did a initial limited 
version of the debugger extension dealing with just ATQ contexts based on
code from NT base.