Some people don't seem to know about that, but...
MSDOS 7 was the kernel used from Win95 to WinMe; the windowing system ran on top of it. It was an hybrid 16/32-bit kernel - thus it could run 'native' 16-bit MSDOS software.
Ever since Windows NT4 was created, atop a VMS-like NT kernel, said kernel could support subsystems used for compatibility reasons. Of note, were those subsystems:
- cmd: a DOS-like command line able to emulate 16-bit DOS - after a fashion. This is the subsystem in question. It has, obviously, sat hardly touched for years.
- (Windows 2000 only, but it worked in XP too) OS/2 subsystem: IBM's extensions to Win16/32 APIs, allowinf OS/2 apps to run under Windows NT5+
- (NT4, dunno about later) POSIX subsystem. Able to run 'Hello World!' in a command line, but unable to access the hardware. Present only to say 'NT4 is POSIX-capable', but not to use it (replaced by Services for UNIX).
The difference between those subsystems and emulators like DOSbox, is that they don't recreate a whole machine+OS; they provide several hooks into NT that may allow an app native to these subsystems to run. Yet they are far from complete.
It is, of course, a bit shameful that any of these subsystems weren't audited for unlimited access into kernel space.