The legal team representing Navy SEAL Edward Gallagher is now accusing his commander of undermining orders from President Trump by imposing “unnecessary and punitive restrictions” on the decorated warfighter in hopes to entrap him and get him “remanded back to the brig.”

The blistering allegations against Naval Special Warfare Group 1 Commodore Capt. Matthew D. Rosenbloom were outlined in a 19-page court motion provided to Fox News just 10 days after the commander in chief tweeted that Gallagher will be moved to “less restrictive confinement while he awaits his day in court” on May 28.

Special Operations Chief Gallagher, who is alleged to have killed an injured ISIS prisoner of war in Iraq, amongst other war crimes, was moved out of the brig at U.S. Marine Corps Air Station Miramar in late March after being confined there since September 2018. Gallagher is now being held at another facility in the San Diego-area, but his lawyers are asserting that Rosenbloom is overstepping his bounds, and in their filing late Tuesday asked a military court to remove the “conditions of pretrial restraint unlawfully placed upon” him.

"Despite numerous attempts to bring the illegality of these actions to CAPT Rosenbloom’s attention, in the hopes that he would reverse course, CAPT Rosenbloom has remained intransigent and defiant of both the Orders of the President of the United States and the principles of the Constitution, which he swore to uphold and defend," lawyer Timothy Parlatore wrote in the filing.

PHOTOS: NAVY SEAL ACCUSED OF WAR CRIMES REUNITES WITH FAMILY

Among the restrictions, his attorneys say:

Requiring him to be in “full uniform of the day at all times between reveille and taps,” and not allowing him to put on civilian clothing “at any time.”

Restricting Gallagher’s movement so his only meal options are “a vending machine and a limited selection of processed food” sold at a convenience store on-site.

Gallagher cannot call or video chat with his wife and children – who are living in Florida – unless he is “in the presence of a command representative or defense attorney.”

Gallagher cannot drive or be driven to his defense team’s offices. He can contact them through a phone outside of his room, but only under the supervision of a command representative or watchstander. Parlatore says this means Gallagher “cannot engage in privileged communication… while a third party is present” and “prohibits him from assisting in the preparation of his own defense.”

In a letter sent to another one of Gallagher’s attorneys last week regarding the dispute over the pre-trial conditions, Rosenbloom stated he “issued those orders under the authority provided in me.”

“I have a reasonable belief: offenses triable by court-martial have been committed; SOC Gallagher committed the offenses; and the restraint ordered is required by the circumstances.

“In line with determinations previously made by both the Internal Reviewing Officer and the Military Judge, I find the stipulations of restriction are required to prevent attempts by SOC Gallagher to intimidate witnesses and obstruct justice,” Rosenbloom added in the letter, also obtained by Fox News.

TRUMP SAYS NAVY SEAL ACCUSED OF WAR CRIMES WILL BE MOVED TO 'LESS RESTRICTIVE CONFINEMENT'

A spokesperson for Naval Special Warfare Command told Fox News on Wednesday that the "President directed the Navy to move Chief Petty Officer Gallagher to a less restrictive confinement" and that the "Navy followed that direction.

"Chief Gallagher is now in a barracks environment, similar to a hotel room. In accordance with the Rules for Court Martial, Capt Rosenbloom is within his authority to place Chief Gallagher in a restricted status," Cmdr. Tamara Lawrence said in an e-mail. "Stipulations outlined for restricted Sailors are determined on a case by case basis. Capt Rosenbloom's letter to the defense counsel speaks for itself.

"The allegations brought forth are serious and the military judicial process must be allowed to play out," she added.

The Commodore also said in his letter that “as has been the case throughout, SOC Gallagher has full access to medical care and legal counsel” – but that was something his attorneys blasted in their court motion.

“Rather than engage in meaningful discussions, CAPT Rosenbloom instead hides behind false pretexts of witness intimidation and false assertions that SOC has full access to his defense team,” they wrote.

“CAPT Rosenbloom cannot possibly have risen to the leadership position he now holds and still lack a basic understanding of the applicable constitutional principles or that limited telephone access from the quarterdeck is not sufficient to communicate with his attorneys,” they added. “The only rational conclusion is that CAPT Rosenbloom fully understands these principles and is flagrantly violating them to attempt to exert undue influence on the outcome of this case.”

In the filing, Gallagher’s lawyers also asked the court to weigh further relief as it deems appropriate, such as a request to allow him to stay with his family in Florida while awaiting the start of his war crimes trial.

CLICK HERE TO GET THE FOX NEWS APP

If convicted on all charges, he faces the possibility of being sentenced to life in prison, they say.

“We respectfully request that this Honorable Court grant SOC Gallagher the relief requested so that he may enjoy his constitutional right to liberty – a right for which he has risked his own life – and so that he may properly and effectively aid in the preparation of his own defense as he fights to maintain his innocence,” they concluded.