The law of conservation of momentum would apply here, as you would have guessed. So the initial momentum of the eject will be equal to the final momentum of fuel and rocket combined. That mass will be $M+m_b$ and it will have a common velocity.
As Möbius points out, the mass of fuel depends on the time for which the rockets are kept in proximity. But we can find out the final velocity.
You can take the final velocity of the combined mass of fuel and the rocket as $v$. So: $$p_{fuel} = v(m_b + M)$$ $$Mu_0 = v(m_b + M)$$ $$\therefore v = \frac{Mu_0}{m_b+ M}$$
Let me know if anything is unclear or I have misunderstood your question.