(CNN) — In an extraordinary move, the Pentagon chief "fired" the Navy secretary for going outside his chain of command by proposing a "secret agreement with the White House," according to a senior defense official.
The agreement that led to Navy Secretary Richard Spencer's forced resignation involved the case of Navy SEAL Eddie Gallagher. The official said Spencer had proposed to the White House a review with a secret guarantee that Gallagher would be allowed to keep his status as a SEAL. That would go counter to the ongoing review underway by the Navy to take away Gallagher's status.
Gallagher was earlier convicted of bringing discredit to the armed services after posing next to a dead ISIS fighter's body, which is against regulations. He was then demoted in rank -- a decision President Donald Trump a week ago reversed in a move that angered military officials. Military officials then moved ahead with the process to review Gallagher's status in the elite group.
Spencer, the official said, was not "fired" for failing to carry out Trump's wishes, because the President had not wanted a review at all.
Spencer went around his own chain of command -- namely Defense Secretary Mark Esper -- and straight to the White House, a violation of military policy, the official said.
Esper on Sunday asked for Spencer's resignation after "losing trust" and "confidence in him," according to a statement released by Pentagon spokesman Jonathan Hoffman. Spencer's private request to restore Gallagher's rank and allow him to retire with his Trident pin directly contradicted his public position, according to the statement.
"I am deeply troubled by this conduct shown by a senior DOD official," Esper said in the statement. "Unfortunately, as a result I have determined that Secretary Spencer no longer has my confidence to continue in his position. I wish Richard well."
When asked for comment, a spokesman for Spencer directed CNN to the Pentagon's statement. Spencer submitted his resignation letter to Trump Sunday.
The Washington Post first reported on Esper asking for Spencer's resignation.
The senior defense official said Esper first learned of Spencer's conversations with the White House on Friday, but that Spencer's proposal was never approved.
When Spencer then spoke over the weekend at the Halifax International Security Forum in Nova Scotia, Canada, Esper felt "his public statements did not match up" with what he had been doing privately, according to the official.
Last week, Trump tweeted that he wouldn't let the Navy punish Gallagher, saying, "The Navy will NOT be taking away Warfighter and Navy Seal Eddie Gallagher's Trident Pin. This case was handled very badly from the beginning. Get back to business!" The Trident Pin, which is worn by Navy SEALs, is awarded following their completion of an intense qualification course and symbolizes membership in the elite military community.
The President's decision not only restored Gallagher's rank but also pardoned two other service members, and in doing so he ignored advice from Esper and other top military officials.
The New York Times reported Saturday that Spencer and Rear Adm. Collin Green, the admiral overseeing the SEALs, threatened to resign over the possible intervention by Trump. Spencer denied later Saturday that either he or Green made any such threat.
Esper decided Gallagher would now keep his status because he "has little confidence that Gallagher would get a fair shake now from the Navy," the official told CNN. Gallagher is now expected to retire from the Navy on November 30.