FILE PHOTO: A combination photo shows U.S. President Donald Trump (L) in the House of Representatives in Washington, U.S., on February 28, 2017 and FBI Director James Comey in Washington on July 7, 2016.
FILE PHOTO: A combination photo shows U.S. President Donald Trump (L) in the House of Representatives in Washington, U.S., on February 28, 2017 and FBI Director James Comey in Washington on July 7, 2016.

The White House says President Donald Trump considered firing then-FBI director James Comey for months, but aides say the U.S. leader increasingly fumed in recent days over Comey's public comments about the criminal investigation of the Trump campaign's links to Russia and regret about his key role in Trump's election.

Trump, according to U.S. news accounts, was angered at Comey's congressional testimony last week in which he outlined the Federal Bureau of Investigation's broad probe into Russia's meddling in last year's presidential election, his refusal to support Trump's unsubstantiated claim that former President Barack Obama wiretapped him, his remark that he was "mildly nauseous" that his actions influenced the outcome of the election and the FBI's seeming disinterest in pursuing government leaks to reporters.

WATCH: Comey statement about 2016 election

"He got tired of him," one White House official told the political news site Politico, referring to Trump and Comey. "I think that's how you would explain it. He got really tired of him."

Still, White House deputy spokeswoman Sarah Huckabee Sanders said Wednesday that Trump did not ultimately decide to fire Comey until after reading a justification for his removal prepared at Trump's request by Deputy Attorney General Rod Rosenstein. That letter outlined Comey's key role in last year's election campaign in investigating Democrat Hillary Clinton's handling of classified documents on her private email server when she was secretary of state from 2009 to 2013.

The Washington Post reported that Rosenstein, Comey's boss, threatened to resign, but has not, after the White House cast him Tuesday night as one of the prime players in firing Comey, with Trump acting on Rosenstein's recommendation.

Trump has said little publicly about Comey's firing, but told reporters Wednesday, "He wasn't doing a good job. Very simple. He wasn't doing a good job."

Comey announced in July, without telling his superiors at the Justice Department, that investigators had determined that Clinton was "extremely careless" in her handling of the national security documents but that no criminal charges were warranted.

Sanders said Comey committed “atrocities in circumventing the chain of command in the Department of Justice. Any person of legal mind and authority knows what a big deal that is.”

FILE - Democratic presidential candidate Hillary C
FILE - Democratic presidential candidate Hillary Clinton speaks with senior aide Huma Abedin aboard her campaign plane at Westchester County Airport in White Plains.

Clinton emails

Trump disparaged Comey's finding in July and often contended on the campaign trail that Clinton should face criminal charges. Trump, however, applauded Comey in late October, just 11 days before the election, when he reopened the FBI's investigation after agents found more of Clinton's emails on the computer of disgraced former congressman Anthony Weiner, sent there by one of Clinton's aides, Huma Abedin, Weiner's wife.

Then, two days before the November 8 election, Comey announced that nothing new had been found in the emails and closed the investigation again.

Clinton last week partly blamed Comey's reopening of the email investigation, even as early voting was occurring, as one of the reasons she lost the election to Trump.

While Comey told the congressional investigative panel that he still felt justified about his handling of the email probe last year, he said he felt "mildly nauseous" that he might have played a role in the election's outcome, another comment that aides say incensed Trump as effectively diminishing his victory over Clinton.

Trump's firing of Comey, in the fourth year of a 10-year term as head of the country's top criminal investigative agency, has engulfed the White House in turmoil, where all but Trump's top aides were unaware he was considering dismissing the FBI chief.

FILE - Senate Minority Chuck Schumer, D-N.Y., spea
Senate Minority Chuck Schumer, D-N.Y., speaks to reporters after a Democratic caucus meeting at the U.S. Capitol in Washington, May 10, 2017.

Call for special prosecutor

Numerous opposition Democratic lawmakers and some Republicans have called for a special prosecutor independent of Trump's Justice Department to carry on the investigation of Trump campaign aides' links to Russia. Republican congressional leaders have balked, saying that ongoing probes of the Trump-Russia connection by Senate and House of Representatives intelligence committees are sufficient.

Even in dismissing Comey, Trump said the FBI director had assured him three times that he, Trump, was not under investigation, and has often disparaged the probe into links his aides have had with Russia. But Sanders refused to say when those conversations occurred and or what exactly was said.

U.S. congressional officials say that Comey had in the days before his firing asked for more resources for his investigation into Russia's involvement in last year's U.S. election. He made the request to Rosenstein, who along with Attorney General Jeff Sessions, outlined in memos the administration's reasons for ousting Comey.

The Department of Justice denied there was such a request by Comey. The outcome and what effect, if any, a request had on Trump's decision to fire Comey are not clear.

Future of probe

Critics of the FBI director's dismissal say it raises questions about the agency's probe.

Career FBI investigators and others at the Justice Department are “going to be very interested in seeing that this moves forward to the extent that there’s evidence there of any wrongdoing, any connection with Russian involvement," former U.S. Attorney General Alberto Gonzalez told VOA. "I would call it a dumb move by the president if he thinks he’s going to stop that investigation."

White House correspondents Steve Herman and Pete Heinlein contributed to this report