Is jailbreaking illegal?
Until mid-2010 Apple fought to make iPhone owners believe jailbreaking was illegal. The company argued in a legal brief presented to the U.S. Copyright Office Library of Congress that jailbreaking constitus copyright infringement.
Because jailbreaking involves unauthorized modifications to Apple's copyrighted bootloader and OS programs, it is a violation...
Jailbreaking, of course, is the process of removing limitations imposed by Apple to gain core access to the operating system of their device so they can get applications and more than aren't licensed by Apple. People jailbreak Apple's iPhone, iPod touch and iPad. They can still make phone calls, in the case of the iPhone, and use the Apple App Store. But people do it, in large part, to get beyond limitations of Apple and its App Store.
Device owners can switch carriers, or they can use third-party apps that aren't approved by Apple.
Despite Apple's contention that jailbreaking is illegal, federal regulators announced in July 2010 that it is lawful to hack or jailbreak an iPhone. They said there is no basis for copyright law to assistant Apple in protecting its restrictive business model.
In other words, if someone buys a device from Apple they are legally free to do with it as they like. So the answer to the question, Is jailbreaking illegal? is no, it's not.
That doesn't mean, however, that Apple has to support jailbreaking. iPhones come with a warranty, and anyone with a jailbroken device is likely to lose that warranty. To get around this, some device owners simply restore their jailbroken device via iTunes before taking it or sending it to Apple for repair. But anything added to the device after jailbreaking will likely be lost.