N.Y. Banking Law § 6020
An agreement between two or more stockholders, if in writing and signed by the parties thereto, may provide that in exercising any voting rights, the shares held by them shall be voted as therein provided, or as they may agree, or as determined in accordance with a procedure agreed upon by them.