Vancouver, Canada CNN Business  — 

The chief financial officer of Chinese tech giant Huawei has been released on bail in Canada, setting her up for a lengthy legal fight over extradition to the United States.

But the case of Meng Wanzhou, who was arrested in Vancouver earlier this month, took on a new dimension after US President Donald Trump suggested he may intervene in the legal saga if it would help his pursuit of a trade deal with China.

Meng’s arrest has stoked tensions between the United States and China, just as the two sides have been trying to negotiate an end to their bruising trade war.

“If I think it’s good for what will be certainly the largest trade deal ever made — which is a very important thing — what’s good for national security — I would certainly intervene if I thought it was necessary,” Trump told Reuters in an interview published shortly after Meng was granted bail by a judge in Vancouver.

The US government alleges that Meng, who is the daughter of Huawei’s founder, helped the company dodge sanctions on Iran. She was arrested December 1 during a layover at Vancouver International Airport.

Huawei is one of China’s leading tech companies. It sells more smartphones than Apple (AAPL) and builds telecommunications networks in countries around the world.

A judge granted Meng, 46, a $10 million ($7.5 million USD) bail Tuesday after three days of court hearings. She left the court in downtown Vancouver on Tuesday evening, according to Canadian broadcaster CBC.

As a condition of her release, she has agreed to surrender her passports and live in one of her homes in Vancouver. She will also pay for an around-the-clock security detail and wear a GPS ankle bracelet.

Meng’s attorney, David Martin, argued that she should be released on bail while she waits for an extradition hearing because of health concerns. Meng has severe hypertension, for which she was hospitalized after her arrest.

Supporters hold signs and Chinese flags outside court in Canada during the third day of a bail hearing for Meng Wanzhou, the chief financial officer of Huawei.

At issue in court was whether Meng posed a flight risk. Martin said she did not, since her ties to Vancouver go back 15 years and she has two homes in the area. Leaving Canada would also embarrass her personally, and would humiliate her father, Huawei and China itself, Martin said.

On Tuesday, Meng’s legal team proposed that the terms of her release could include financial pledges from people in Canada who know her, such as a realtor and insurance agent. Together, they pledged more than $3 million ($2.2 million USD) in home equity and cash, which they’d owe if Meng flees. Her husband also offered to put up the couple’s two houses in Vancouver.

The judge agreed to those terms. Of Meng’s $10 million bail, $3 million is pledged by her sureties, the people responsible for making sure she complies with the orders set forth by the court. The other $7 million ($5.2 million USD) is a cash deposit from Meng.

Meng posted a message on her private WeChat account a few hours after posting bail, saying she was in Vancouver, back by her family’s side. WeChat, owned by internet giant Tencent (TCEHY), is the dominant social media platform in China.

“I’m proud of Huawei, and I’m proud of my motherland! Thank you for your concern,” she wrote, according to Chinese state media.

Her arrest had been met with consternation from Chinese officials. The Chinese Foreign Ministry said over the weekend that it had summoned both US Ambassador to China Terry Branstad and Canadian Ambassador to China John McCallum to address Meng’s detention, which it described as “lawless, reasonless and ruthless.”

In addition to her role as CFO of Huawei, Meng serves as deputy chairperson of the company’s board.

Huawei said in a statement that the company has “every confidence that the Canadian and US legal systems will reach a just conclusion” in the case. The company reiterated that follows all the laws and regulations where it operates.

The United States alleges that Meng helped Huawei get around US sanctions on Iran by telling financial institutions such as HSBC (HSBC) that a Huawei subsidiary, Skycom, was a separate and unaffiliated company.

The US Justice Department has declined to comment on the case. Meng faces “serious charges of fraud involving millions of dollars” in the United States, according to the affidavit of a Canadian law enforcement official. She could receive substantial jail time if convicted, the statement said.

The process of approving or denying Meng’s extradition is expected to take months. Meng is due back in court February 6.

The United States has 60 days from the date of a provisional arrest to provide Canada with its formal extradition request and supporting documents. Canada’s Justice Department then has 30 days to weigh the request and greenlight an extradition hearing in which the request is weighed by a judge.

Joe Sutton, Sherisse Pham and Serenitie Wang contributed to this report.