Section 197(1) in The Code of Criminal Procedure, 1989 (1933 A. D.)
(1)When any person who is Judge within the meaning of section 19 of the Ranbir Penal Code or when any Magistrate, or when any public Servant who is not removable from his office save by or with the sanction of the State Government or the Government of India, is accused of any offence alleged to have been committed by him while acting or purporting to act in the discharge of his official duties, no Court shall take cognizance of such offence except with the previous sanction-(a)in the case of persons employed in connection with the affairs of the Union, of the Government of India ; and(b)in the case of persons employed in connection with the affairs of the State, of the Government.