A receiver, an assignee of an insolvent debtor, or a trustee or other officer, appointed by a court or a judge, is a public officer, within the meaning of this article; but where he was appointed by or pursuant to the order of a court, or in proceedings supplementary to execution against property, the application for leave to prosecute his official bond or undertaking must be made to the court by which, or pursuant to whose order, he was appointed, or in which the judgment was rendered, as the case may be.
N.Y. Pub. Off. Law § 28