All moneys paid into any court of the United States, or received by the officers thereof, in any case pending or adjudicated in such court, shall be forthwith deposited with the Treasurer of the United States or a designated depositary, in the name and to the credit of such court.
This section shall not prevent the delivery of any such money to the rightful owners upon security, according to agreement of parties, under the direction of the court.