Let's restrict ourselves to:
- A 1+1 dimensional spacetime,
- Lorentz boosts (as opposed to other coordinate transformations).
The reason to restrict ourselves to Lorentz boosts, is essentially so that we stay within the mathematical framework of special relativity, without getting into tools that require general relativity. (J. Murray's answer nicely interprets this question using a general relativistic framework by discussing how the spacetime metric transforms). Physically, Lorentz boosts are the transformations that relate inertial observers (in the absence of gravity), so this assumption boils down to assuming we only want to consider inertial observers and we are neglecting any gravitational effects.
The trajectory of a photon can be specified by giving the $x$ as a function of $t$ (in general you'd want to give both $x$ and $t$ in terms of a parameter $\lambda$, but there's no need to make the formalism that complicated in this example). An example trajectory would be
$$
x = x_0 + ct
$$
for some constant $x_0$. The 3-velocity is, of course, $c$:
$$
v = \frac{dx}{dt} = c
$$
Now we perform a Lorentz transformation to move from the $(x, t)$ frame to the $(x', t')$ frame, related by a boost with velocity parameter $v$
\begin{eqnarray}
t' &=& \gamma \left(t - \frac{x v}{c^2}\right) \\
x' &=& \gamma\left(x - v t\right)
\end{eqnarray}
What happens to our trajectory? Well, inverting the above transformation, and plugging it back into the trajectory, yields...
\begin{eqnarray}
x &=& x_0 + ct \\
\gamma\left(x' + v t'\right) &=& x_0 + c \gamma \left(t' + \frac{x' v}{c^2} \right) \\
x' \left(1 - \frac{v}{c}\right) &=& x_0 + c t' \left(1 - \frac{v}{c}\right) \\
x' &=& \frac{x_0}{1 - \frac{v}{c}} + c t'
\end{eqnarray}
In other words, the initial position has transformed, but the 3 velocity $dx'/dt'$ is still $c$.
Now, you may notice that the above derivation involves canceling factors of $1-v/c$. What happens if $v=c$? Then $1-v/c=0$, and it is not valid to divide by zero.
This is actually the question you're interested in; a Lorentz transformation to the rest frame of a photon would involve using a boost parameter equal to $c$.
In fact, the issue with taking $v=c$ already arises in the first line. The factor $\gamma=1/\sqrt{1-v^2/c^2}$ becomes infinite when $v=c$, and therefore the Lorentz transformation itself is ill-defined. (Incidentally, for $v>c$, $\gamma$ becomes imaginary, which also means the Lorentz transformations don't make physical sense for $v>c$!)
A more sophisticated way to interpret this geometrically is that the inner product of two 4-vectors remains invariant under a Lorentz transformation. In particular, the sign of the inner product remains invariant. This allows us to divide separations between points in spacetime into timelike separated regions (I usually work in a convention where these have a positive norm), spacelike separated regions (which have a negative norm in my convention), and null separated regions (which have zero norm). A Lorentz transformation cannot change the sign of the inner product, so they cannot change a timelike vector into a spacelike vector, or a null vector into a timelike vector. Photon trajectories are null paths, and therefore remain null after a Lorentz transformation.
Finally, as stated in the comments, while this answer gives a few different perspectives as to why you cannot construct a photon rest frame within the framework of special relativity, in fact special relativity itself is built by assuming the speed of light is the same in all inertial reference frames. So logically speaking, these arguments should be considered as consistency checks, but not really a "proof".