It's not illegal, it's part of politics. I don't like it, and neither do many people, but that's politics. Sometime, however, short term politics like this may cost the players another win in the long-run, as people perceive them as un-ethical (regardless whether it's justified or not).
I see it more as McCain's people move than Huckster's, though.