Problem

Source: Morrocan TST 2005 (Pb 9)

Tags: number theory proposed, number theory



Find all the positive primes $p$ for which there exist integers $m,n$ satisfying : $p=m^2+n^2$ and $m^3+n^3-4$ is divisible by $p$.