Let $n$ be an odd natural number greater than $1.$ Find the two smallest $n$ such that $n$ is a factor of $2023^n-1.$ Show that infinitely many such $n$ exist.
The only progress I've made is finding the smallest solution: $3.$ I haven't found any other solution yet. I found $3$ relatively easily as $2023\equiv_31.$ I tried solving $2023\equiv_n1.$ This gives $2022=nk$ for $k\in\mathbb{N}.$ This doesn't have infinite solutions, though. How to proceed?
PS: This was a question on an exam that ended $4$ hours ago.
Using Euler theorem, when $n$ is coprime with $2023$ (which clearly happens for infinitely many odd $n$), $2023^{\varphi(n)} \equiv 1 [n]$. Therefore, we must look for $n$ such that $\varphi(n)|n$. In this case, $n = \varphi(n)k$ for an integer $k$ and $2023^n \equiv (2023^{\varphi(n)})^k \equiv 1 [n]$.
Look for $n =$ power of a prime number, their Euler's totient function are easy to compute.