A judge rules that attorney had been sent back to prison from home confinement as retaliation for his plan to release a book critical of the president before November election