The iPhone has had multiple "Malware" issues, even on unjailbroken phones.
(
http://www.engadget.com/2007/07/23/safari-exploit-gives-hackers-full-control-of-your-iphone/)
The reason? It's a mainstream device.
And to bring jailbreaking into it... Jailbreaking is a pretty extensive bootrom hack that has major effects on the device, positive or not is not an issue for debate... but for every iPhone version since around about 1.1.1, there has been gaping secure-design flaws that allow an ENTIRE COMPRIMISE.
Worse is they (Apple) have tried to combat it by fixing it with software updates just for a new one to be discovered indicating that even when having a security hole rubbed in their face, they are just as inept as most other manufactures at securing their products that consumers put their trust in.
Again, this happens cause there is a tangible gain for attacking iPhone/iPods... the public use them on a large scale unlike say Mac which is generally creative arts and home users (Speaking generally of course).
And no, not every vulnerability is exploited but here is the kicker... Only a VERY SMALL percentage of vulnerabilities are disclosed to the vendors by security researchers. Many more are circulating unpatched in the cyber-criminal underworld being exploited for gain that will never be "reported". This is true for all OS/Devices/Security holes.
ALWAYS assume that just because the public/vendors are not aware of any open critical vulnerabilities, it does not mean that they are not already being exploited by the bad guys.
This notion that OSX is more secure than anything else is a joke.