Former White House official and Donald Trump ally Steve Bannon’s effort to toss his contempt of Congress convictions faced a skeptical federal appeals court panel Thursday, as judges questioned Bannon’s claim that executive privilege should have protected him from prosecution.

Last year, a federal jury found Bannon guilty of two counts of contempt of Congress for defying a subpoena from the House select panel investigating the Jan. 6, 2021, attack on the Capitol.

Bannon did not provide any documents and did not sit for a deposition and was sentenced to four months in prison, which has been paused during the appeal.

An attorney for Bannon told the U.S. Court of Appeals for the District of Columbia Circuit on Thursday that the trial judge should have allowed Bannon to argue that he relied on his lawyer’s advice, which was that former President Trump asserted executive privilege and that it protected Bannon from testifying.

David Schoen said Judge Carl Nichols should have “at least let a jury decide” whether Bannon relied on his attorney’s advice in good faith.

Schoen argued that once Bannon’s first attorney, Robert Costello, told the Jan. 6 committee that executive privilege had been invoked, it was “presumptively valid.” And he said Congress should have challenged that executive privilege claim instead of recommending Bannon for contempt charges.

But D.C. Circuit Judge Cornelia Pillard pointed out that Bannon left a White House post in 2017 and none of the activities covered by the panel’s subpoena came during Bannon’s time in the White House.

Pillard also noted that Trump did not himself communicate to the committee that he was invoking executive privilege and a decision for Bannon would be a decision against congressional power.

“Why wouldn’t we be saying that Mr. Costello’s representations override a congressional committee’s ability to investigate?” Pillard said.

Schoen said it “doesn’t matter” whether executive privilege was actually invoked, just that Costello told Bannon it had been. Schoen said that once Costello told Bannon and the committee that executive privilege had been invoked, Bannon thought he was behaving legally by avoiding the subpoena.

Bannon should have been able to assert that as a defense at trial, and the executive privilege “changes everything, the entire dynamic of the case,” Schoen said.

“Never in our system is Congress the arbiter of a subpoena,” Schoen said.

Judge Bradley N. Garcia pointed out that the D.C. Circuit’s most recent case on the issue, from the 1960s, didn’t allow for that kind of defense.

The rare oral arguments over Congress’ power to hold recalcitrant witnesses in contempt came more than two years after the House panel first sent Bannon the subpoena.

Throughout the litigation leading up to last year’s trial, Nichols ruled against Bannon several times on his trial defenses as well as his efforts to subpoena committee staff, documents and members of Congress. Those rulings all formed part of the appeal.

Schoen said Bannon should have been able to at least question panel Chairman Bennie Thompson, D-Miss., about letters he sent urging Bannon to “continue to comply” with the subpoena. He argued that may have contributed to Bannon’s belief that he wasn’t in contempt.

Pillard pushed back on that argument and said that although Congress may still have taken Bannon’s testimony after the subpoena deadline, a deadline was a deadline. Someone who misses the deadline to file their taxes may have violated the law, but they also still must file their taxes, Pillard said.

“You’re drawing an inference that I’m not sure [the letter] supports,” Pillard said.

Justice Department attorney Elizabeth Danello argued Bannon was warned multiple times that his executive privilege assertion did not make him immune from the subpoena.

“Mr. Bannon deliberately chose not to comply with a legitimate congressional subpoena,” Danello said.

Danello said prior court decisions have held that a congressional witness cannot rely on advice of counsel to dodge a subpoena. Courts have decided the law requires “only that the defendant acted deliberately and with intent,” she said.

At one point Judge Justin R. Walker said it “seems a little weird” that the government sought rulings against what Bannon was allowed to use a defense at trial and then argued at trial that he had no justification for refusing the subpoena. But Walker said the government is “probably” correct when Danello said that Bannon did in fact have no legally valid defense.

Bannon, a longtime Trump ally, was one of only two witnesses before the select committee who were prosecuted for contempt of Congress. The other, Peter Navarro, was found guilty on two counts of contempt of Congress earlier this year. Navarro is scheduled to face sentencing in January.