Neither the state, nor any county, city, town, or village, nor any state board, nor any state, county, city, town, or village officer, suing in his official character, shall be required to pay costs before commencing a suit, nor to give security for costs before or after the commencement of a suit.