§ 142-d. Rental or hiring of town highway machinery, tools or equipment. Except as otherwise provided in section one hundred forty-two-c of this chapter with respect to the use of town highway machinery, snow and ice removal equipment, tools and equipment by a village located wholly or partly within the town, the town superintendent of highways, with the approval of the town board, may permit the use of any town-owned highway machinery, tools or equipment by a county or any municipality, district, district corporation, school district, community college, and any unit of the state university of New York, upon such terms and conditions as may be agreed upon by the parties involved. Moneys received by a town pursuant to the provisions of this section shall be applicable for the purposes for which amounts may be raised as provided in subdivision three of section two hundred seventy-one of this chapter.