The governing authorities of municipalities shall have the power to construct all needful improvements in the harbor; to control, guide, or deflect the current of a river; to repair and regulate public wharves and docks; to charge and collect levee rates and wharfage on firewood, lumber, timber, logs, shingles, staves, posts, laths, and other articles brought to the port of such municipality; and to set aside or lease portions of the wharf for special purposes. However, a permit to use any portion of a wharf or a lease of the same shall not be granted for a term exceeding twenty-five years.