I am trying to understand Einstein's mass-energy equation $E=mc^2$. Knowing about the atomic bomb, I am inclined to believe that $E$ is proportional to the mass: $E=Cm$. For this equation to be dimensionally correct $E$ must also be proportional to some speed squared. We can use the "speed-limit of the universe" $c$. So $E=C \times mc^2$. But why does $C$ turn out to be 1? Should the equation really be: $E\propto mc^2$?
The above reasoning takes a "leap of faith". If I assume that energy is proportional to mass the equation follows (except maybe for a constant).
I am looking for the simplest way to prove this. I read about Einsteins box in which a photon is emitted from one end towards the other. This seem to offer a simple way to derive this equation. If I accept that the photon has a momentum: $p=E/c$, even though it has no mass it follows from conservation of momentum that the photon has a “relativistic mass”: $m = E/c^2.$
However I also read that $E=mc^2$ only applies to a resting object (not photons) and that in general: $E^2=p^2c^2+m^2c^4$.
But does this does not mean that one cannot understand $E=mc^2$ from Einsteins box? What is the point of this thought experiment then?