On Tuesday, a federal judge delayed the sentencing of Michael Flynn, President Donald Trump‘s first national security adviser, after condemning the former lieutenant general for lying to the FBI about his discussions with the Russian ambassador in 2016 during the presidential transition period.

Judge Emmet Sullivan described Flynn’s crimes as “a very serious offense” and expressed his “disgust” at the former three-star general’s actions.

Flynn pleaded guilty in December 2017 to lying to federal investigators about his conversations with former Russian Ambassador Sergey Kislyakbut was recommended title to no prison time by special counsel Robert Mueller earlier this month due to his “substantial assistance” with the Russia inquiry. Despite Flynn’s cooperation with Mueller’s team, Judge Sullivan will ultimately determine the length of his prison sentence.

On Monday, two of Flynn’s former business associates — one of which, Bijan Kian, was a member of Trump’s transition team — were charged with conspiracy related to the extradition of a Turkish cleric who was accused of launching a coup against Turkey’s government. Flynn had confessed in his guilty plea to failing to register his two former associates as agents lobbying on behalf of the Turkish government, led by President Recep Tayyip Erdogan. 

“All along you were an unregistered agent of a foreign country while serving as the national security adviser,” Judge Sullivan told Flynn in a scathing rebuke at Wednesday’s hearing. “Arguably that undermines everything that this flag over here stands for. Arguably you sold your country out.”

SLIDESHOW: DONALD TRUMP’S 30 CRAZIEST TWEETS

Despite all this, the judge gave Flynn the option to postpone his sentencing until his cooperation deal with prosecutors is over.

According to several reports, Flynn faces up to six months behind bars, although prosecutors have pushed for a more lenient term — including potential probation — due to his cooperation in many probes.

50 CELEBRITIES WHO DIED IN 2018 – TRIBUTE SLIDESHOW

Earlier this month, Flynn’s legal team claimed the FBI may have duped the former general into lying and that investigators had failed to inform him prior to his interview nearly two years ago that misleading them is a crime. When asked about this excuse by Judge Sullivan, Flynn said he was aware lying to the FBI was a federal crime.

On Wednesday morning, Trump wished Flynn — one of Trump’s few former associates who he has not explicitly criticized but instead has apparently spoken well of — “good luck” on Twitter for his sentencing hearing in court.

“There was no Collusion!” Trump reiterated in his tweet.

Flynn, 60, is an admired former general who once led the Defense Intelligence Agency. He was interviewed 19 times by Mueller’s team over the last year. Flynn is now the highest-ranking former Trump associate to receive a prison sentence.