A backfire through the carburetor can occur when there is fire in a cylinder and an intake valve open. Pretty difficult to get the backfire through a closed intake valve.
If the timing is right then the valve shouldn't be open (maybe the valve is damaged).
If the valve is closed when it should be, then the ignition shouldn't have fired.
Solution:
Compression test, followed by full ignition test using an oscilloscope.
Jon.