One way of rephrasing your question is "Can Apple write firmware that is 100% free of any bugs that could allow running of arbitrary code?", and the answer is "No."
While I believe Apple to be the among the best software companies, for the past 50 or so years, I don't think anyone has ever written an entirely bug-free piece of software, let alone one as complex as iPhone OS. What has happened so far, and what will continue to happen, is the cat and mouse game: With every new iPhone OS, Apple patches previous bugs allowing jailbreaks, and hackers find new ones.
Laws of programming:
1. A program can always be made simpler.
2. There's always one more bug.
Therefore by extension, any program can be made into a one line bug.