Answer :

They both have the same momentum, not kinetic energy.
When bullet is fired it weights let's say 10 grams (0,01 kg) and has velocity of 1000m/s.
The rifle which weights 10000 grams (10kg) has velocity 1 m/s.
The momentum is equal.

But to calculate kinetic energy you have to use formula
 
Lets calculate:
Bullet's kinetic energy= 1/2*0,01*1000^2 = 5000 J
Rifle's = 1/2*10*1=5 J

So the velocity has much larger impact on kinetic energy than mass.