Updated

The Obama administration said Saturday that it has officially received Army Sgt. Bowe Bergdahl’s request for a pardon, while the soldier’s lawyers work on a backup plan to have their client’s charges dismissed after President-elect Donald Trump takes office.

Bergdahl is the former prisoner of war accused of endangering comrades by walking off his post in 2009 in Afghanistan.

Bergdahl’s original pardon request was apparently sent Friday to President Obama through the Justice Department, and the secretary of the Army received a copy. But it was not formally requested through the military chain of command, Fox News learned.

If Obama grants the clemency request before leaving in January, Bergdahl could avert a military trial scheduled for this spring, when he will face charges of desertion and misbehavior before the enemy.

The misbehavior charge carries a maximum penalty of life in prison.

However, if the pardon isn't granted, Bergdahl's defense team plans to expand its legal strategy by filing a motion arguing Trump violated its client’s due process rights with scathing public comments about the case.

Bergdahl, of Hailey, Idaho, was held captive by the Taliban and its allies for five years after walking off his post.

The Obama administration's decided in May 2014 to exchange him for five Taliban prisoners held at Guantanamo Bay, Cuba, prompted criticism that included some Republicans accusing Obama of jeopardizing nation's safety.

Some lawmakers were outraged that the administration didn't give Congress a 30-day notice about transferring the detainees, as required by law.

Shortly after Bergdahl was returned to U.S. custody, President Obama’s national security adviser, Susan Rice, said he served his country with “honor and distinction.”

Throughout his presidential campaign, Trump criticized Bergdahl, saying repeatedly the soldier is a traitor who would have been executed in the "old days."

During a July speech in Indiana, Trump lamented that Bergdahl could wind up with a light punishment.

"Remember the old days? A deserter, what happened?" he said before pantomiming pulling a trigger and adding: "Bang."

And in an August 2015 campaign event, Trump called Bergdahl a “dirty, rotten traitor.”

Bergdahl lawyer Eugene Fidell declined Saturday to comment on the pardon request. But he said he plans to file a motion seeking dismissal of the charges against Bergdahl shortly after the January inauguration, arguing that Trump violated his client's constitutional due-process rights.

“All of these things put together and repeated rally upon rally for basically a year have a cumulative effect that I think is totally at odds with the right to a fair trial," Fidell said.

The defense has been noting Trump's comments about Bergdahl in what they've dubbed the "Trump Defamation Log." A version included in the court record lists 40 such instances as of August.

A spokeswoman for Trump didn't respond to emails this weekend seeking comment.

There is precedent for a military judge to decide a president's comments have tainted a military prosecution.

In 2013, a Navy judge cited comments by Obama when he issued a pretrial order that two defendants in sexual assault cases couldn't be punitively discharged if they were found guilty.

The judge wrote that Obama's public comments about cracking down on sexual assault, specifically referencing dishonorable discharges, appeared to be demand particular results from military courts.

The Associated Press contributed to this report.