With Java being able to run on every type of computer...

Cristatus

Diamond Member
Oct 13, 2004
3,908
2
81
Is it not possible to make a virus that would be able to infect Linux, Max, and almost any computer out there (obviously only limited by Java's compatibility)?

Would this not be dangerous seeing that Java is compatible with many different systems, and a virus is only a set of instructions meant to destroy a computer?

DISCLAIMER: i don't know how to code, but i'm just asking out of interest.
 

kamper

Diamond Member
Mar 18, 2003
5,513
0
0
First of all, the single virus would have to have a way to exploit all those different platforms. A hole that exists on windows probably isn't going to be exploitable on any other platform. Since a successful virus usually spreads by going after a single hole, or a few related holes, it's really not likely that anyone would bother to give a virus multiple ways to spread.

Second, it's just not worth writing a virus for non-windows systems. They are generally better secured and fewer in number. Not saying that no one will ever write a virus for other platforms, but if you're going to go that far, it's probably worth your time to port the virus because you're probably going to have to write some platform specific code anyways.

Also, java lacks a good mechanism of accessing local apis, like win32, so that will limit a virus's ability to wreak havoc.