“I Know You’re In There Somewhere” Fight: Averted. If you think one of these is going on, you’re being Wrong Genre Savvy, and quite possibly, you’re being suckered by someone who thinks that they know that you’re Wrong Genre Savvy. Neither downloading-and-replacement, nor editing into compliance leave the original person in their brain, never mind capable of doing anything. Nor do possession or puppeteering leave them any way to control their own body, under virtually any circumstances.
Standard procedure, therefore, is to kill the zombie and restore from backup. If you need the information they might have acquired before getting caught and pithed, well, shoot to incapacitate and hope that once you get their brain back to the lab it turns out to be a quick-and-dirty puppet job, because that’s the only way it’ll be there any more.
Brainwashing For The Greater Good: The Imperial legal system’s penalties for pretty much every non-capital crime above the level of a misdemeanor (or for chronic misdemeanants) include, along with the fine/reparation, “memetic rehab and recon”, which is Exactly What It Says On The Tin, namely, having your mind edited to remove whatever bad ideas made you commit your special crime.
They are, of course, perfectly fair about this and do offer you the option to prize your self-integrity over your ethical stature. Depending on the magnitude of said special crime, you always receive the alternative option of either (a) renouncing your citizen-shareholdership and departing forthwith into exile, or (b) euthanasia.
(Note: Also, when you consider how this looks from the inside, remember that people perform mental editing on themselves all the time for various self-developmental purposes, including moral growth. Also also, there are many fewer laws in the first place.)
Brainwashed: The jargon term is “edited into compliance”. With perverted sophotechnology – or its equivalent for pure-biologics – and the large pile of quantum supercomputers you need to defeat the many safety features which exist to stop people doing things like this, it’s really not all that hard to do some personality editing to make people do whatever you need them to do.
Of course, it’s personality editing that shows up fairly obviously to a comparison of mind-state backups, am-I-me service, or the equivalent, so whatever you’re going to brainwash people to do, make sure that they can do it quickly and without entering the kind of super-high-security facility that considers it worth delaying everyone who tried to get in to check their mindprint. But it’s still a useful technique for the resource-rich and ethically challenged.