I’m surprised no one’s brought up the quote.
“With or without it [religion], you’d have good people doing good things and evil people doing bad things, but for good people to do bad things, it takes religion.”
—Steven Weinberg, Nobel Laureate in physics
I’m not saying I agree with it, it just ties in nicely with your question. :P
Okay, for an actual answer, I’m going to be a total nerd and answer that yes, bad people can do good things, as seen in InuYasha when Sesshoumaru “adopts” Rin. It’s nice and sweet and totally out of character for Sesshoumaru unless we understand that bad people aren’t one-dimensional, we just often judge them that way because it’s easier to comprehend/hate.
(There are definite exceptions to this, but I think in RL, prisoners adopting/caring/rehabilitating (for) dogs is a good example of the idea that bad people aren’t just bad; they’re human, and human motivation/psyche is affected by so many things that summing up an entire person’s existence in a word is simpleminded, at best.)