The making of profit, directly or indirectly, by the state treasurer, out of any money in the state treasury belonging to the state, with the custody of which the state treasurer is charged, by loaning or otherwise using it, or the removal by the state treasurer, or by his consent, of such money or any part thereof out of the vault or safe of the treasurer's department, or out of any legal depository of such money, except for the payment of the sums authorized by law to be paid, for the purpose of depositing the same, under the provisions of chapter 4-6, in banks which shall have qualified as depositories, is a Class 6 felony, and the treasurer shall be liable upon his official bond for all profits realized from such unlawful use of such funds.
SDCL 4-5-1