A person who, in the presence of a court or magistrate, assaults or threatens to assault another, or commit an offense against his person or property, or who contends with another with angry words, may be ordered by the court or magistrate to give security, as provided in Section 5565, or if he refuses to do so, he may be committed as provided in Section 5566.
Okla. Stat. tit. 22, § 49