DOS programs under "screen"

Andy Koppe
Fri May 1 19:26:00 GMT 2009

2009/4/21 Barry Kelly:
> Windows implements console mode as a client-server protocol between the
> executable (ntvdm.exe for DOS apps) and winsrv.dll (hosted in
> csrss.exe), but the protocol isn't easily hookable. I guess one would
> have to hijack the console APIs, perhaps by stepping into the
> application using debugging APIs and overwriting the DLL imports, but it
> would be pretty painful.

Hi Barry, have you got any pointers to documentation or reverse
engineering attempts for that console protocol?

2009/4/21 Christopher Faylor:
> It can be done using the same technique as Console2:

I don't understand how. ReadConsoleOutput() on the hidden console only
gives you the cooked output in terms of character cell contents and
attributes, whereas the raw output as it came from the console app
would need to be sent to the pty to be displayed by the likes of
screen. As far as I can see, recreating the raw output from the cooked
one isn't possible in general.

This article has more on this:


Unsubscribe info:
Problem reports:

More information about the Cygwin mailing list