<s>[INST] The Diophantine Equation: $x^3-3=k(x-3)$ I wish to know how to resolve the diophantine equation: $x^3-3=k(x-3)$ ? The problem is:

Find all integers $x\ne3$ such that $x-3\mid x^3-3$.
- From 250 Problem's in Elementary Number Theory, by W. Sierpinski

I have found the solutions to this problem by using rules in divisibility of numbers, as below:
$$x-3\mid x-3 \Rightarrow x-3\mid x^3 - 3x^2$$
$$x-3\mid x^3-3 \quad and \quad x-3 \mid x^3-3x^2$$
Thus, $x-3$ divides their difference:
$$\Rightarrow x-3\mid 3x^2-3  $$ 
On the other hand:
$$x-3\mid x-3 \Rightarrow x-3 \mid 3x^2-9x$$
Hence their difference is divisible by $x-3$:
$$\Rightarrow x-3\mid 9x-3 \quad and \quad x-3\mid 9x-27$$
$$\Rightarrow x-3\mid 24 \Rightarrow 24=k(x-3)\Rightarrow x=\frac{24}{k}+3$$
So we have the general solution to find the integer values of $x$. But I did not manage to solve the diophantine equation related to the problem: $$x^3-3=k(x-3)$$
Any hints and helps about this equation?  
-Thank you in advance.
 [/INST] Set $x-3=y\iff x=?$
$$\dfrac{x^3-3}{x-3}=\dfrac{(y+3)^3-3}y=y^2+9y^2+27y+\dfrac{3^3-3}y$$
So, $y$ must divide $3^3-3=24$ to keep $k$ an integer
</s>