The justices of the supreme judicial court, of the superior court, and of district courts may cause all laws made for the preservation of the public peace to be kept; and in the execution of that power may require persons to give security to keep the peace, or for their good behavior, or both, as provided in this chapter.
Mass. Gen. Laws ch. 275, § 1