It's a interesting inspection!

We can prove this by using our knowledge in the class

We consider $2$ and $3$ as special cases since $2^2-1$ and $3^2-1$ are both divisors of $24$

For any prime $p\neq2,3$, we know that $2\nmid p$ and $3\nmid p$

On one hand, since $2\nmid p$, $p=2k+1,k\in\mathbb{Z}$

so $p^2-1=(2k+1)^2-1=4k^2+4k=4k(k+1)$, we know that one of $k,(k+1)$ must be even

hence $2\mid k(k+1)$, therefore $8|4k(k+1)=p^2-1$

On the other hand, since$3\nmid p$, we know that $p=3k\pm1,k\in\mathbb{Z}$

so $p^2-1=(3k\pm1)^2-1=9k^2\pm6k=3k(3k\pm2)$ is divisible by $3$

hence $3\mid p^2-1$

since $8\mid p^2-1$ and $3\mid p^2-1$, we know that $24\mid p^2-1$

hence for any prime $p\neq2,3$, $p^2-1$ is a multiple of $24$

and for $p=2,3$, $p^2-1$ is a divisor of $24$

that is, $p^2-1$ is either a multiple or a divisor of $24$