The attorney general has the powers in sections 8.31 and 501B.40 and 501B.41, to supervise and investigate corporations under this chapter and to bring proceedings to secure compliance.