Guangzhi Cao, a former engineer at Tesla, admitted in a court filing this week that he uploaded zip files containing Autopilot source code to his personal iCloud account in late 2018 while still working for the company. Tesla sued Cao earlier this year for allegedly stealing trade secrets related to Autopilot and bringing them to Chinese EV startup Xiaopeng Motors, also known as Xmotors or XPeng, which is backed by tech giant Alibaba.

Cao denied stealing sensitive information from the automaker in the same filing. His legal team argued he “made extensive efforts to delete and/or remove any such Tesla files prior to his separation from Tesla.” Cao is now the “head of perception” at XPeng, where he is “[d]eveloping and delivering autonomous driving technologies for production cars,” according to his LinkedIn profile.

According to a joint filing from the two parties that was also filed this week, Tesla has subpoenaed documents from Apple. While Apple is not involved in this case, a former employee who worked on the tech companys secretive autonomous car project was charged by the FBI with stealing trade secrets last July.

That employee allegedly Air Dropped sensitive data to his wifes laptop and was also caught on CCTV leaving Apples campus with a box of equipment. He had left his job at Apple to take a position at XPeng before being arrested. Cao was also a senior image scientist for Apple for two years before he joined Tesla, according to his LinkedIn profile.

The suit comes at a time when the US is locked in a trade war with China and has accused the nation and some of its biggest companies of committing so-called “economic espionage.” Tesla, Apple, XPeng, and a lawyer for Cao did not respond to requests for comment.

In a statement to The Verge earlier this year, XPeng said it opened an internal investigation into Teslas allegations, and that it “fully respects any third-partys intellectual property rights and confidential information.” XPeng said it “by no means caused or attempted to cause Mr. Cao to misappropriate trade secrets, confidential and proprietary information of Tesla, whether such allegations by Tesla being true or not,” and said it “was not aware of any alleged misconduct by Mr. Cao.”

Tesla filed its suit against Cao this past March. The former employee was one of around 40 people with direct access to the source code for Autopilot, which is Teslas advanced driver assistance system. The company claimed Cao began uploading “complete copies of Teslas Autopilot-related source code” to his personal iCloud account late last year. Cao zipped and moved more than 300,000 files and directories related to Autopilot, according to the complaint.

At the end of 2018, Cao allegedly deleted 120,000 files off his work computer, disconnected his personal iCloud account, and deleted his browser history all around the same time he accepted a job with XPeng, an EV startup based in China that makes cars that look very similar to Teslas. Tesla also claimed Cao recruited another Autopilot employee to XPeng in February.

Cao admits he “used his personal iCloud account to create backup copies of certain Tesla information in 2018” in the new court filing. He also admits he created zip files containing Autopilot source code in late 2018, and confirmed that XPeng extended him an offer letter on December 12th. He says he disconnected his personal iCloud account from his Tesla-issued computer “on or around December 26,” and that he kept logging into Teslas networks between December 27 and January 1st, 2019.

While Cao does not specify when he formally accepted the job at XPeng, Tesla says his last day was January 3rd. He also denies poaching any employees from the Autopilot team.

Cao “further admits that he deleted certain files stored on his Tesla comp