I mostly just meant you wouldn't be breaking laws technically to go around them via reverse engineering. To your second statement that's actually a good point, it could be. I mean in general overall it's going to be pretty outrageous to try and legitimately develop going around apple entirely, so the OP's point is valid de facto, just saying in principle they can't lock people out in the absolute sense under current law.
First, violating terms of service isn't illegal - ToS isn't the law, it's a contract; breaching contract terms isn't illegal but may expose you to some liabilities depending on the contract.
Second, terms of service don't always apply, you may refuse them, and then you're not even in breach of contract. Things like shrink-wrap/click-through EULAs aren't binding contracts in Norway; so the default provisions of copyright law apply, which allows reverse engineering without the permission of the copyright holder.