If any loan or guaranty is made in violation of Section 18436 or 18442, the directors and officers who authorize it or assent thereto are jointly and severally liable to the company as guarantors for the repayment or return of the sum or value so loaned with interest thereon at the rate of 6 percent per year until paid.