How do you apply a filter after DFT on an image?
Based on your C++ snipped, the correct way to do complex multiplication between samples of DFT sequences should be as follows:

$$ Z[k] =  X[k]\cdot Y[k] = (a + jb)(c+jd) = (ac-bd) + j (ad+bc) $$

Where the real part of the result is $ac-bd$, and the imaginary part is $ad+bc$.

Then you can take the inverse 2D-DFT.

Note that, for an alias free circular convolution implementation, your DFT length should be at least $100 + (5-1)/2 = 102 \times 102$ points. Then after the inverse DFT of $ 102 \times 102 $ points, discard the first $2$ rows and columns and reatin the remaining $100 \times 100$ part which are the samples of the filtered image.