U.S. President Donald Trump speaks during a meeting on border security in the Cabinet Room of the White House | Brendan Smialowski/AFP via Getty Images Trump lashes out at FBI after report he was investigated over national security Bureau action was prompted by firing of director James Comey and included a counterintelligence component regarding Russia.

U.S. President Donald Trump on Saturday lashed out following a New York Times report that said the FBI opened an inquiry into the commander in chief shortly after he fired FBI Director James Comey that centered on whether Trump was a national security threat to his own country.

"Wow, just learned in the Failing New York Times that the corrupt former leaders of the FBI, almost all fired or forced to leave the agency for some very bad reasons, opened up an investigation on me, for no reason & with no proof, after I fired Lyin’ James Comey, a total sleaze!" Trump tweeted.

According to the Times' report, published online Friday and in print Saturday, the FBI's investigation was related to whether Trump had obstructed justice by firing Comey but also included a counterintelligence component on whether Trump was knowingly working for Russia or had fallen under the Kremlin's influence — a revelation that had not been previously reported.

"This is absurd," White House press secretary Sarah Huckabee Sanders said in a statement provided to POLITICO late Friday. "James Comey was fired because he’s a disgraced partisan hack, and his Deputy Andrew McCabe, who was in charge at the time, is a known liar fired by the FBI."

Friday's report was based in part on the accounts of unnamed former law enforcement officials, "others familiar with the investigation" and former FBI general counsel James. A Baker's private congressional testimony.

The report details a "vigorous debate" among former law enforcement officials about whether the probe was an overreach.

The report further states that the bureau's investigation, including the counterintelligence aspect, was taken over by special counsel Robert Mueller, whose appointment was put into motion by Trump's decision to fire then-FBI Director James Comey on May 9, 2017.

The president has repeatedly changed his reason for firing Comey. The White House initially said Trump fired Comey at the recommendation of Deputy Attorney General Rod Rosenstein, who penned a memo suggesting firing Comey over his handling of the investigation into Hillary Clinton’s use of a private email server.

However, several days later, the president told NBC’s Lester Holt that he fired Comey over the investigation into Russian collusion.

Deputy Director McCabe was fired from the FBI in March 2018 just hours before his retirement, following criticism from Trump and allegations by an internal Justice Department watchdog that he misled investigators probing the FBI's handling of the 2016 Hillary Clinton email investigation.

In an acknowledgment of just how serious an FBI investigation of a sitting president would be, the report details a "vigorous debate" among former law enforcement officials about whether the probe was an overreach.

Rudy Giuliani, Trump's attorney, said the FBI's investigation into Trump should have resulted in an outcome, otherwise the bureau is "imperiling our national security." But legal experts pointed out that a counterintelligence investigation is different from a criminal probe and the lack of previous public knowledge of the investigation or of any possible outcomes is not surprising.

"If it was a counter intelligence investigation and it obtained any evidence, it would have to have resulted in some action being taken or they are imperiling our national security," Giuliani said in a statement to MSNBC. "This shows how out of control they are."

The report drew quick reaction among legal analysts on social media. Carrie Cordero, an adjunct law professor at Georgetown, said the report showed a "cautious" FBI "not eager" to investigate the president.

Renato Mariotti, a former federal prosecutor and Democratic candidate for Illinois Attorney General, said the report showed the FBI opened a counterintelligence probe "because it had good reason to believe that Trump was secretly working on behalf of Russia against our interests."

The Times previously reported that Trump, in a meeting with Russian officials in the Oval Office shortly after Comey's ouster, bragged that "pressure" on him was now alleviated.

"I just fired the head of the F.B.I. He was crazy, a real nut job,” Trump allegedly said. “I faced great pressure because of Russia. That’s taken off.”