§ 279-a. Determination of tax. If any person fails to pay any tax required by this article, the commissioner of taxation and finance shall determine the amount of tax due at any time within five years after the tax became payable and shall give written notice of such determination to the person or persons liable therefor. Notwithstanding any of the foregoing provisions of this section, where, before the expiration of the time prescribed in this section for the determination of tax, both the commissioner of taxation and finance and the taxpayer have consented in writing to its determination after such time, the tax may be determined at any time prior to the expiration of the period agreed upon. The period so agreed upon may be extended by subsequent agreements in writing made before the expiration of the period previously agreed upon. Such a determination shall finally and irrevocably fix the tax unless the person against whom it is assessed shall within thirty days after the mailing of notice of such determination petition the division of tax appeals for a hearing. After such hearing the division of tax appeals shall give written notice of the determination of the administrative law judge to the person against whom the tax was assessed and to the commissioner of taxation and finance. Such determination may be reviewed by the tax appeals tribunal as provided in article forty of this chapter. The decision of the tax appeals tribunal may be reviewed as provided in section two thousand sixteen of this chapter but the proceeding may not be commenced unless the amount of tax stated in the determination with penalties thereon, if any, shall have first been deposited with the commissioner of taxation and finance and an undertaking filed with him in such amount and with such sureties as a justice of the supreme court shall approve to the effect that if the proceeding be dismissed or the determination confirmed the petitioner will pay all costs and charges which may accrue against him in the prosecution of the proceeding or at the option of the petitioner such undertaking may be in a sum sufficient to cover the tax, penalties, costs and charges aforesaid in which event the petitioner shall not be required to pay such tax and penalties as a condition precedent to the commencement of the proceeding. The remedy provided by this section for a review of the decision of the tax appeals tribunal shall be the exclusive remedy available to judicially determine the liability for taxes under this article.