No foreign corporation transacting business in this state without a certificate of authority shall be permitted to maintain an action in any court in this state until such corporation shall have obtained a certificate of authority; nor shall an action be maintained in any court by any successor or assignee of such corporation on any right, claim, or demand arising out of the transaction of business by such corporation in this state until a certificate of authority to transact business in this state shall have been obtained by such corporation or by a corporation which has acquired all, or substantially all, of its assets. If such assignee shall be a purchaser without actual notice of such violation by the corporation, recovery may be had to an amount not greater than the purchase price. This section shall not be construed to alter the rules applicable to a holder in due course of a negotiable instrument.
The failure of a foreign corporation to obtain a certificate of authority to transact business in this state does not impair the validity of any contract or act of such corporation, and shall not prevent such corporation from defending any action in any court of this state.
Any foreign corporation which transacts business in this state without a certificate of authority shall forfeit and pay to this state a penalty, not exceeding $1,000, and an additional penalty, not exceeding $100, for each month or fraction thereof during which it shall continue to transact business in this state without a certificate of authority therefor. Such penalties may be recovered in the district court of any county in which such foreign corporation has done business or has property or has a place of business, by an action, in the name of the state, brought by the attorney general.