A dive into the world of MS-DOS viruses
blog.benjojo.co.uk
blog.benjojo.co.uk
1) buffer 1 keystroke in memory (so typing diw<backspace>r would leave "di" on screen - then they'd type "r" and get an "r" and then hit enter and get another "r", then they'd hit backspace to correct the "dirr" and the command would execute, etc)
2) hooked the printer interrupt to introduce typos in printouts
3) randomly swap letters on the screen periodically
Fun times. It's probably for the best that I grew up in the era that I did since pulling pranks like these has a high risk of getting slapped with felony charges in this day and age.
The executable forked off a prank process which simulated the effect of the professor doing a write to the teaching assistant's TTY.
The fake professor's console message claimed that he happens to be looking at the same homework, which looks quite good and deserves a solid 19/20.
And so when I got this back, the mark was 19/20 with a note saying "Well, <profname> told me to". Haha!
Random error messages
Reboot randomly
Create unusual files
And yet the antivirus can't find anything. :)
BBS lists, Turbo Debugger and that giant purple & white Microsoft Press book with most of the Int 21h calls. Undocumented DOS, Undoc PC and Abrash's books were also helpful. Later, there were good free resources.
Yeah, DOS viruses were bad: booting off an infected floppy, infected HD or running untrusted code was all it took. In Windows, it was worse because autorun would run untrusted code automatically without warning.
There were some darn useful TSR's like Super PC-kwik Power Pak, QEMM and Desqview. Stacker and Doublespace/DriveSpace were kinda slow but did (mostly) work. Stacker had an accelerator card IIRC. And a commercial white bag/gray box mod for Welltris, Mouse Commander, added mouse support to Welltris for DOS by doing some mouse driver to keyboard translation in a TSR that was loaded and unload in a wrapper .BAT file. Many trainers, no-cd/runtime cracks and cheats also used TSR tricks to run.
Qemm was the single best thing that ever happened to DOS-using me. The second best was Windows 95.
The open office was probably invented as a countermeasure for the boss key.
[1] https://www.mobygames.com/game/leisure-suit-larry-goes-looki...
The first thing I did when I got internet access in 1996 was look up information on how how to write TSRs (oh, and stuff about X-Files) as I did not have access to any books on the subject.
What the heck was I using? MASM? TASM? I cannot remember.
IIRC, looking for other .com files was just using DOS's FindFirst and FindNext functions at int 21h. (I'm now naming them in terms of their Win32 counterparts.)
I think I didn't have a sanity check against duplicate infection in the early versions and added that during testing. 17 year old's programmer's "doh" moment.
I remember that I ran the experiments in a subdirectory called "petridir". :)
I think it's an interesting way of holding the PC hostage.
A video of the virus in action: https://www.youtube.com/watch?v=wdZJHvBRRqg, that channel has loads of videos documenting DOS/Win9X viruses. Some are very creative.
EDIT: typo.