It most likely is illegal. The files belong to the company; you are not allowed to copy, remove, or use them for  your own benefit, even to try to establish that you did not steal. (Note: if there is a lawsuit or legal proceeding against you, there are legal mechanisms--e.g. "discovery"--to lawfully gain access to the information and documentation.) Therefore, what you have done is most likely illegal; also if you signed any confidentiality agreement(s) re: company information, their terms are enforceable, too.