A banned motorcyclist who attacked a police man and woman after being detained for racing a car has been jailed for five months.