A Brooklyn federal magistrate refused on Tuesday to release a key witness in special counsel Robert Mueller’s probe who is accused of transporting child pornography, but OKd a plan for two FBI agents to drive him to face charges in Virginia, officials said.

George Nader, the witness facing porn charges in federal court in Virginia, was arrested Monday in New York City after arriving on an overseas flight. His lawyer sought release under guard to a medical facility to handle complications from recent open heart surgery.

Nader, 60, was held in the federal jail in Brooklyn overnight. U.S. Magistrate Cheryl Pollak said he would be picked up Wednesday and transported to Alexandria, Virginia, by two agents, one of them a paramedic, according to officials.

A Lebanese-American publisher with ties to President Donald Trump’s campaign, Nader became a figure of interest in Mueller’s investigation for brokering a 2017 meeting in the Seychelles between a Trump associate and Russian bankers linked to Vladimir Putin.

Early last year, investigators seized phones from Nader, and he testified multiple times before a grand jury convened by Mueller. One of the phones also had short videos with young boys, including display of their genitalia and sexual activities with goats.

Virginia prosecutors swore out a sealed criminal complaint in April 2018. Nader has a home in Dubai, and his lawyer said he was arrested when he arrived to consult with a heart specialist at a Mount Sinai Hospital in New York City.

Defense lawyer Christopher Clark said Nader was willing to pay for round-the-clock armed guards to keep him from fleeing so that he could receive medical care for his heart outside of prison.

Sign up to get the latest updates Get Newsday's Breaking News alerts in your inbox. By clicking Sign up, you agree to our privacy policy.

Nader faces a mandatory minimum prison sentence of 15 years if he is convicted. He was previously convicted of transporting child pornography in 1991. Clark did not respond Tuesday to a request for comment.