"My opinion is that the cartoonist did nothing illegal. In a democracy many things are said, some truthful and others false," Katju said in a statement.
Trivedi was arrested yesterday and produced in a Mumbai court which sent him to police custody till September 16. He was arrested following a complaint that he had put up banners mocking the Indian Constitution during the Anna Hazare rally held last year in Mumbai.
To drive home his point, Katju recalled his own words as a judge and said he used to often say in court that people can call him a fool or crook inside the court or outside but he will never initiate contempt of court proceedings, because either the allegation is true, "in which case I deserve it, or it is false, in which case I will ignore it".
"These are occupational hazards, and politicians, like judges, must learn to put up with them," Katju said.
He maintained that arresting a cartoonist or any other person who has not committed a crime is itself a crime under the Indian Penal Code as it is a wrongful arrest and wrongful confinement.
"So policemen, who make such illegal arrests, cannot take the plea that they were obeying orders of political superiors," he said.
Citing another example, he said, "During the Nuremberg trials, the Nazi war criminals took the plea that orders are orders, and that they were only obeying the orders of their political superior Hitler. But this plea was rejected by the International Tribunal which held that illegal orders should be disobeyed."