The Code of Criminal Procedure, 1973 (CrPc)
106. Security for keeping the peace on conviction.
(1) When a court of Session or court of a Magistrate of the first class convict a person of any of the offences specified in sub-section (2) or of abetting any such offence and is of opinion that it is necessary to take security from such person for keeping the peace, the court may, at the time of passing sentences on such person, order him to execute a bond, with or without sureties, for keeping the peace of such period, not exceeding three years, as it thinks fit.
(2) The offences referred to in sub-section (1) are-
(b) Any offence which consists of, or includes, assault or using criminal force or committing mischief-,
(e) Any offence of criminal intimidation;
(d) Any other offence which caused, or was intended or known to be likely to cause, a breach of the peace.
(3) If the conviction is set-aside on appeal or otherwise, the bond so executed shall become void.
(4) An order under this section may also be made by an Appellate court or by a court when exercising its powers of revision.