In most countries reverse engineering is completely legal, and creating another system that does the same thing is completely legal. If you get "inside info" or obtain information on the system in any illegal way, then the product you create is also illegal.
See Sony vs. bleem! case.
By the same argument, it is not legal to release Kickstart ROM's - because they the property of their respective owners, it is nothing you created. However, if you created an Amiga emulator you could reverse engineer the system in such a way that it would not need the ROMs (i.e. to find out what they are needed for, and simulate those calls) and thus your Amiga emulator could still be completely legal. Exactly this happened with bleem! and it was proven 100% legal.
Take ScummVM, it implements a reverse engineered version of the game engine created by Lucas Arts. Since it contains no material from the original games
it is legal (assuming you didn't get any inside info, etc - something difficult to prove either way).
About Coca-Cola. How would you reverse engineer that? Even if you could, how would you be able to prove that you did not just take the recipe which was published in the Sun newspaper a few years ago?