Problem

Source: Croatia TST 2016

Tags: number theory, Diophantine equation, prime numbers, primes



Find all pairs $(p,q)$ of prime numbers such that $$ p(p^2 - p - 1) = q(2q + 3) .$$