Prove $4p-3$ is a square knowing that $n\mid p-1$ and $p\mid n^3-1$, $p$ prime
Note $p \mid n-1$ is impossible because $n \le p-1$, so we have $p \mid n^2+n+1$.
Since $n \mid p-1$, we can write $p = an+1$ for some integer $a \ge 1$. Since $p \mid n^2+n+1$, we can write $$n^2 + n + 1 = bp = b(an+1)$$ for some integer $b \ge 1$.
Reducing modulo $n$ gives $1 \equiv b \pmod{n}$, so write $b = rn+1$ for some integer $r \ge 0$. Putting this in the above equation gives $$n^2 + n + 1 = (rn+1)(an+1).$$
If $r \ge 1$, then $(rn+1)(an+1) \ge (n+1)^2 > n^2+n+1$, which is a contradiction. So $r = 0$, $b = 1$, and $n^2 + n + 1 = p$, so we get $4p-3 = (2n+1)^2$.