A former Tesla security employee named Karl Hansen has filed a whistleblower complaint with the SEC, accusing the electric vehicle maker of covering up theft and spying on workers. He's the second ex-Tesla employee to come forward.

Hansen, like former Tesla technician Martin Tripp, is represented in his complaint by attorney Stuart Meissner. In a statement through Meissner on Thursday, Hansen accused Tesla of:

Failing to disclose to shareholders that $37 million worth of copper and other raw materials were stolen from the Gigafactory in the first half of 2018

Spying on employees, specifically by wiretapping and hacking their cellphones and computers

Failing to disclose to local law enforcement and to the U.S. Drug Enforcement Administration that a Gigafactory employee may have been involved in drug trafficking

Retaliating against Hansen for raising such issues, internally, by firing him in mid-July

Tesla CEO and Chairman Elon Musk, in an interview with Gizmodo, questioned Hansen's credibility.

A Tesla spokesperson wrote in a separate press statement:

"Mr. Hansen's allegations were taken very seriously when he brought them forward. Some of his claims are outright false. Others could not be corroborated, so we suggested additional investigative steps to try and validate the information he had received second-hand from a single anonymous source. Because we wanted to be sure we got this right, we made numerous attempts to engage further with Mr. Hansen to understand more about what he was claiming and the work that he did in reaching his conclusions. He rejected each of those attempts, and to date has refused to speak with the company further. It seems strange that Mr. Hansen would claim that he is concerned about something happening within the company, but then refuse to engage with the company to discuss the information that he believes he has."

Meissner emphasized in an email to CNBC that Hansen authorized the release of his name and details about the case. "I do not want other whistleblowers to think that we distribute their identity or even discuss their matters publicly at all, as we do not, unless they request such," Meissner said.

The attorney also explained why he thinks the SEC and Tesla shareholders might be interested in the complaint.

"The concern is about material information and omissions to shareholders, and whether or not this information was shared with Tesla's board of directors as well. A failure to report a $37 million theft obviously would appear to impact books and records. There could be criminal aspects of this complaint that raise concern in other regulatory agencies related to wiretapping, which is a federal crime, and failure to cooperate with the DEA and Storey County sheriff's task force with regard to the issue of drug trafficking."

The DEA declined to comment.

The Storey County Sheriff's Office said, in a statement, that it could not "confirm nor deny the existence of an ongoing investigation of drug activity that is connected to the Gigafactory." The sheriff's office acknowledged that it had received reports of theft at the Gigafactory, investigated, and referred cases to the district attorney there for a prosecutorial decision.

Hansen's accusations come at a time of intense scrutiny for Tesla and Musk. The CEO recently drew fire for tweeting that he was looking to take the company private at $420 a share and had "funding secured."

Tesla shares closed down 1 percent at $335.45 on Thursday and are now below their price at the time of Musk's tweet.

Ongoing investigations at Tesla do not indicate a finding of wrongdoing, but could shake investors' confidence. Meissner has a long history working with the SEC and whistleblowers. He previously represented a former Monsanto executive who alleged accounting fraud, leading to a settlement of $80 million between the SEC and Monsanto in 2016.