How the inverse square law in electrodynamics is related to photon mass? I have read somewhere that one of the tests of the inverse square law  is to assume nonzero mass for photon and then, by finding a maximum limit for it , determine a maximum possible error in $\frac{1}{r^{2+\epsilon} }$ for $\epsilon$ .
My question is: (in the context of classical physics)


*

*How are these two related and what is the formula relating them?

*Why measuring photon mass is easier than  testing the inverse square law directly? (Indeed it seems more challenging!)
 A: Regarding your first question. When you are asking it, you should understand that it has an answer only in some model -- there is no universal relation that holds in every imaginable model of electromagnetic interactions. I personally do not know a model that would break the inverse square law in the way you want.
However, if you accept that electromagnetic field is described by some local quadratic Lagrangian, then I believe that the fact that photon posseses some mass $m$ would imply for the potential something like:
$$
\phi\propto \frac{e^{-mr}}{r},
$$
in units where $\hbar=c=1$. It is the Yukawa potential. Well, may be for EM it is a liitle bit different, but the point is that there is some exponential decay. There is an intuitive explanation for this fact: a virtual photon of mass $m$ can exist only for a time about $1/m$ so that it can propagate to a distance $1/m$. This means that the range of the EM intraction will be about $1/m$ ($\hbar/mc$ in usual units).
Also, quantum corrections alter the inverse square law at small distances in a rather complicated way, but it is a different story. Also, in priciple EM field could develop an anomalous scaling dimension due to quantum effects, but I think that it is protected by gauge invariance. (Someone correct me if I'm wrong).
