Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Coraline

Microsoft releases DOS source code

Recommended Posts

I wonder if this can be used to reverse engineer dos games without the need of their source codes.

Share this post


Link to post
Avoozl said:

I wonder if this can be used to reverse engineer dos games without the need of their source codes.


I'm curious as to how that would work out, exactly. How can having the source code for a software A help you reverse engineer the source code for software B?

Share this post


Link to post
Avoozl said:

I wonder if this can be used to reverse engineer dos games without the need of their source codes.

Technically, it can help a little bit by allowing to make modified versions of DOS that contain better debuggers and stuff to look at a DOS program's execution in real time.

But that can already be done with DOSBox.

Besides, those are DOS 1.1 and 2.0. To be really interesting, it would have to have been at least MS DOS 6.22, or at least something no older than MS-DOS 5.0.

Share this post


Link to post

Since a DOS program could've been written in 100% raw assembler and throw DOS entirely out of the window during runtime, having the SC for DOS itself would not help much, if at all. It would be much more useful to have info on the specific compiler and libraries used for a particular program.

Having the SC to DOS itself would only help with debugging certain "cleanly" written programs that use DOS services extensively. But games were usually anything but cleanly written...DOS had both the "curse" and the "grace" of not doing much by itself, so it left software relatively free to do as it wished with your system (single user, single task...). This also means that there's little to be gained by having the SC to such a minimalist OS, especially one which has been reversed engineered/documented/copied so many times already.

Share this post


Link to post

I remember a game on the glorious PC1512. You could boot with a DOS floppy and then run it, sure; but you could also boot with the game's own floppy, then it booted into the game. In either case, the game couldn't be quit properly, you had to reset the computer.

If there had been more games like that, a PC without a hard drive could have basically worked like a big cumbersome console.

Share this post


Link to post
Gez said:

I remember a game on the glorious PC1512. You could boot with a DOS floppy and then run it, sure; but you could also boot with the game's own floppy, then it booted into the game. In either case, the game couldn't be quit properly, you had to reset the computer.

If there had been more games like that, a PC without a hard drive could have basically worked like a big cumbersome console.

That was how everything worked on systems like the Apple IIe and Commodore. Put in floppy A, turn it on. It boots off the floppy, spends the next 10 minutes reading the entire thing into RAM, and then asks for floppy B. 10 minutes after THAT, you're ready to play Oregon Trail in gigantic green phosphor pixels.

Share this post


Link to post
Avoozl said:

I wonder if this can be used to reverse engineer dos games without the need of their source codes.


That'd certainly be interesting. As Gez mentioned, though, there's already DOSBox that can run many DOS programs on a modern OS.

Share this post


Link to post
Clonehunter said:

If it can reverse engineer anything, here's hopes to good working Chasm: The Rift and PowerSlave source ports.


I really doubt either of these games would have run on MS-DOS 2.0.

For reference, MS-DOS 2.0 does not support FAT16 (so maximum partition size was under 16 megabytes) and it does not support floppy disk drives either. So, don't even bother dreaming of somehow loading MSCDEX with it; and both those games were distributed on CD-ROMs.

These two DOS versions that MS opened are entirely useless for gaming. They have no purpose and will not help anyone anywhere.

Share this post


Link to post
Gez said:

For reference, MS-DOS 2.0 does not support FAT16 (so maximum partition size was under 16 megabytes) and it does not support floppy disk drives either.


Actually, it does support floppy disks, just not high density (1.2MB) 5.25" ones, nor 3.5" DD (720K) ones. Why do you think they called it DOS? How do you think DOS itself was distributed?

Tape was never a primary medium for software distribution on the IBM PC (and compatibles), even though infamously GWBASIC and BASICA supported loading/saving from/to tape.

And I still haven't understood how reverse-engineering an OS that was just pushed aside by applications and games would help with debugging, especially with protected mode games.


Is there still some mysterious, undocumented service routine that NONE has successfully replicated or figured out yet? Now, if this was e.g. Windows NT's source code, then YES, we'd have something.

Share this post


Link to post

That, and the fact that the people who programmed the games in the first place didn't have access to the DOS source.

Share this post


Link to post
Maes said:

Now, if this was e.g. Windows NT's source code, then YES, we'd have something.

Even then, it probably wouldn't be a whole lot of help. The main thing that makes reverse engineering hard is finding a starting point. If the compiler is known then all the interfaces between the program and the OS or run time can be automatically labelled by tools such as IDA Pro. IDA Pro even has a debugger and a decompiler.

So if the goal is rebuilding the source code to relatively modern programs, we have the tools. The problem is modern programs are just far too large for doing so to actually be realistic. That and compiler optimizations obfuscating the machine code.

Share this post


Link to post
Technician said:

Couldn't this be used to create the closest to vanilla dos emulator?

In the same way that the source code for Commander Keen could be used to create the closest to vanilla Quake port.

The DOS people want to emulate is MS-DOS 6.

Share this post


Link to post
Gez said:

To be really interesting, it would have to have been at least MS DOS 6.22, or at least something no older than MS-DOS 5.0.

How can you forget the infamously broken MS-DOS 4.00?

Share this post


Link to post
Linkrulezall said:

How can you forget the infamously broken MS-DOS 4.00?

Easily.

Share this post


Link to post

So maybe freedos wasn't really freedos? Unless first few versions of DirectX source code is released, I don't see what the big deal is. It pisses me off I still can't play Resident Evil 1 and other games under Windows 9X virtualization with hardware accelerated 3D.

Where's the motivation for DosBox authors to make a fork for virtualized mode? Mortal Kombat Trilogy runs damn slow in dosbox.

Share this post


Link to post
Holering said:

It pisses me off I still can't play Resident Evil 1 and other games under Windows 9X virtualization with hardware accelerated 3D.

Where's the motivation for DosBox authors to make a fork for virtualized mode? Mortal Kombat Trilogy runs damn slow in dosbox.

Considering that Resident Evil 1 was designed for two very specific video cards and only had a correctly implemented timer for one of them, it's highly unlikely that the Direct X source code would do you much in terms making the game playable.

The PC versions were programmed like complete shit, and in all seriousness, I have a nagging suspicion that the PlayStation version isn't that much better. Based on the tidbits I've gleaned from the Resident Evil hacking community, all three games were very hacky in terms of programming. For example; based on what I can tell from RE1's level format, all monsters should respawn when you reenter a room, but don't due to a series of flags set within the level file when a monster is killed. In other words, object death isn't handled by the entity / game object itself, but is merely a "flag" that is toggled on and off. Said flags are checked every time a player enters a room.

Share this post


Link to post

It's pretty funny and rather sad that they're only willing to release the source code to DOS 2.0, and even then, only under a highly restrictive "academic only" license. Presumably DOS 3.0 and later still contain some highly valuable trade secrets that they can't possibly release?

After all these years Microsoft is still as uptight and scared of open source as it ever was.

Share this post


Link to post
fraggle said:

It's pretty funny and rather sad that they're only willing to release the source code to DOS 2.0, and even then, only under a highly restrictive "academic only" license. Presumably DOS 3.0 and later still contain some highly valuable trade secrets that they can't possibly release?

After all these years Microsoft is still as uptight and scared of open source as it ever was.

Yeah. Problem is with their high API stability, for one thing. The internals of Office 2013 probably don't look very different from the internals of Office 95. Given one, you could implement a ton of the nice/useful stuff from newer versions with a good team of programmers and have a competing product.

Not to mention in cases like the above, the prior versions were in a lot of ways superior to the garbage they religiously push now. So many people hate the ribbon for example, but it's a permanent fixture and keeps invading even more programs. I'm currently getting driven crazy by it being in Outlook 2010 on my new dev VM at work. I want my menu back.

Share this post


Link to post
BlueFeena said:

Considering that Resident Evil 1 was designed for two very specific video cards and only had a correctly implemented timer for one of them, it's highly unlikely that the Direct X source code would do you much in terms making the game playable.

The PC versions were programmed like complete shit, and in all seriousness, I have a nagging suspicion that the PlayStation version isn't that much better. Based on the tidbits I've gleaned from the Resident Evil hacking community, all three games were very hacky in terms of programming. For example; based on what I can tell from RE1's level format, all monsters should respawn when you reenter a room, but don't due to a series of flags set within the level file when a monster is killed. In other words, object death isn't handled by the entity / game object itself, but is merely a "flag" that is toggled on and off. Said flags are checked every time a player enters a room.

Interesting. I've seen bits and pieces of this all over the place, and I'm pretty sure it's a hoax, but apparently the first few RE games (1, 2, 3) where made with the Quake engine, and CV was made with the Quake 2 engine. Not sure how valid it is, but it would make a certain amount of sense. I've always had that weird vibe about those games running on that tech..

Share this post


Link to post
fraggle said:

It's pretty funny and rather sad that they're only willing to release the source code to DOS 2.0, and even then, only under a highly restrictive "academic only" license. Presumably DOS 3.0 and later still contain some highly valuable trade secrets that they can't possibly release?


Well, seeing how Windows 9x/Me still WERE DOS under the hood and those are less than 25 years old...that might indeed be the case.

Plus, later versions of DOS (and Windows 9x) were infamous for doing various kinds of "dirty tricks" if you tried to install them alongside competing products, e.g. DR DOS or Novell DOS were certainly targeted, and making a "sanitized" release certainly isn't one of their prioritites.

Share this post


Link to post
Quasar said:

Yeah. Problem is with their high API stability, for one thing. The internals of Office 2013[...]

I guess holding back later versions of Word is vaguely understandable; I was really referring to the DOS source code. They haven't sold any version of DOS or any Win9x OS (arguably based on DOS) for over a decade. What are they afraid of at this point?

I honestly think Microsoft are just utterly paranoid about making anything public at all. Rather than a generous move on their part, it just looks completely ridiculous.

Not to mention in cases like the above, the prior versions were in a lot of ways superior to the garbage they religiously push now. So many people hate the ribbon for example, but it's a permanent fixture and keeps invading even more programs. I'm currently getting driven crazy by it being in Outlook 2010 on my new dev VM at work. I want my menu back.

I've talked to quite a few people who were initially skeptical but after a while seemed to really like the Ribbon - in Office, at least. Personally I never liked it and I'm glad I don't have to deal with any of that shit any more. I remember particularly disliking the "Ribbon buttons as tabs" interface in Outlook 2007.

The worst part about the Ribbon is that they seem to have latched onto it as something vaguely successful and "innovative" and subsequently sought to apply it to all of their products. I laughed when I saw it integrated absurdly and unnecessarily into MS Paint, but in other places it's worse: here's a great summary of how they ruined the Windows Explorer interface, for example.

Share this post


Link to post

I kinda get the hate on the ribbon, but if you haven't been frequently using the older versions of Office for 15+ years, or what ever point it takes to really drill those menus into your muscle memory, the ribbon really does make shit easier to find.

Share this post


Link to post
flubbernugget said:

I kinda get the hate on the ribbon, but if you haven't been frequently using the older versions of Office for 15+ years, or what ever point it takes to really drill those menus into your muscle memory, the ribbon really does make shit easier to find.

For Word, Excel, etc. I can kind of believe that. They're complicated beasts with a huge number of features that are difficult to navigate. My beef is more with Microsoft now forcing the Ribbon into absolutely everything they make, even where it makes no sense at all and brings no benefit.

Personally I also dislike the Ribbon just because it makes for a visually cluttered, messy-looking interface.

Share this post


Link to post

Yeah, I have to disagree with the ribbon making things easier to find. With menus, at least, you have things organized by category so you can mostly find the commands you need by considering what kind of action they fall under. It seems like the ribbon's only goal is to make an icon for every damned feature the software has.

This might work with Paint, where the entire feature set of the software fits on one line, but not so much with Office and Visual Studio.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×