§ 6026. Security for expenses in stockholders' derivative action brought in the right of the corporation to procure a judgment in its favor. In any action specified in section six thousand twenty-five, if the plaintiff or plaintiffs hold less than five percent of any class of the outstanding shares or hold a beneficial interest in shares representing less than five percent of any class of such shares, then unless the shares and beneficial interest of such plaintiff or plaintiffs have a fair value in excess of fifty thousand dollars, the corporation in whose right such action is brought shall be entitled at any stage of the proceedings before final judgment to require the plaintiff or plaintiffs to give security for the reasonable expenses, including attorney's fees, which may be incurred by it in connection with such action and by the other parties defendant in connection therewith for which the corporation may become liable under this article, under any contract or otherwise under law, to which the corporation shall have recourse in such amount as the court having jurisdiction of such action shall determine upon the termination of such action. The amount of such security may thereafter from time to time be increased or decreased in the discretion of the court having jurisdiction of such action upon showing that the security provided has or may become inadequate or excessive.