A virus or a trojan are pieces of code which automate an attack, and propagate more or less automatically (the terminology is a bit sloppya bit sloppy). First there must be a vulnerability which can be exploited to run malicious code on the target. There are many kinds of vulnerabilities, including a gullible user who will "open executable attachments" (the core principle of many a trojan), but there must be some. Then, the virus/trojan/malware brings it up to a higher level through automation.
With a vulnerability, the attacker gains some control on one car. Most attackers will stop there, because they are car thieves and don't want to take the control of any other car than the one they are standing next to. Even more so, they don't want to steal a car which is "too much damaged", be it mechanically or logically.
A car virus, "infecting" a lot of cars, would allow for large-scale heists, e.g. plunging a whole car-loving country into pedestrian chaos, or blackmailing authorities with the prospect of killing random drivers (gee, when I write that, I almost hear the voice of Bruce Willis cracking jokes while shooting villains). While this would be a great Hollywood scenario, I expect massive car-stealing to occur first. We will get warnings.
A redeeming property of cars is that they are not electronically centralized, not in the same was as a smartphone. An iPhone has a single big CPU which does everything. A car has dozens of small CPU, each responsible for one or two tasks. Though they are linked together, they still have a lot of autonomy. A remote exploit on a car would probably allow for shutting it down, or blinking lights, but not override everything. Car manufacturing regulations are also adamant: come what may, the driver must still be able to brake by heavily pushing on the pedal, even in case of a total collapse of electronics, e.g. after having been hit by lightning. The hand-brake, also, is supposed to be entirely mechanical, with no electrical part. As long as these properties are maintained, you cannot be abducted by your own car, even if it has "automatic driving" abilities.