§ 117. Certain contracts and expenditures prohibited. Except as authorized by law, no officer, board, department or commission shall during any fiscal year expend or contract to be expended any money or incur any liability or enter into any contract which by its terms involves the expenditure of money for any purpose, unless provision therefor shall have been made in the annual budget, and in no case in excess of the amount appropriated for such year, except pursuant to section one hundred twelve of this chapter and further excepting such leases and contracts as may have been entered into by the town for a term exceeding one year in accordance with the provisions of this chapter or any other law applicable to such town. Nothing in this section shall be construed to prevent the allowance of any claim by the town board for any lawful town purpose in excess of the amount appropriated for such year for such purposes, where the said town board has by resolution transferred sufficient funds to said budgetary fund in accordance with section one hundred twelve of this chapter, and nothing in this act shall be construed to prevent the town supervisor or the town comptroller from paying amounts in excess of the amounts appropriated for such year in the annual budget where such transfer has been made, nor shall anything in this act be construed to require a town which has entered into a lease or contract for a term exceeding one year to pay during the current year any amounts larger than those which become due and owing during that year under the terms of such lease or contract. Any contract, verbal or written, made in violation of this section, shall be null and void as to the town and no money belonging to the town shall be paid thereon. Nothing herein contained shall be construed to prohibit the town board from making contracts for periods exceeding one year for the purposes of improvement districts whenever authorized by law.