It is the right of a witness to be protected from irrelevant, improper or insulting questions, and from harsh or insulting demeanor, to be detained only so long as the interests of justice require it, and to be examined only as to matters legal and pertinent to the issue.
Utah Code § 78B-1-136