Search code examples
assemblybiosdata-protectionreal-mode

Protect BIOS from very aggressive program


For the sake of experiment, I plan to run program X in realmode.

Program X will make a random routine, and execute it (I want to see what will happen).

But I worry that this program eventually damages the BIOS permanently.

Is there a way to protect the BIOS from this aggressive program?


Solution

  • As @Jester suggested, just use a virtual machine. DOSBox, Bochs, and maybe QEMU are nice for 16-bit emulation. Because, if you are really unlucky (I don't know what exactly you mean with "random," though) you might end up with a corrupted CMOS, a flashed BIOS, or other corrupted hardware. In Real Mode, anything is possible, so running on a real machine might lead to serious damage.

    You might also try writing a Protected Mode wrapper and run the code in Virtual 8086 Mode. Not quite the same as Real Mode, but at least you're not going to destroy your system.