WASHINGTON — Newly discovered emails found on a computer seized in an investigation of disgraced former congressman Anthony Weiner thrust the controversy over Hillary Clinton’s use of a private server back into the presidential campaign less than two weeks before the election.

Officials said the discovery prompted a surprise announcement Friday by FBI Director James Comey that the agency would once again be examining emails related to Clinton’s time as secretary of state.

In a letter to lawmakers, Comey said the FBI would take “appropriate investigative steps” to determine whether the newly discovered emails contain classified information and to assess whether they are relevant to the Clinton server probe.

The emails, numbering more than 1,000, were found on a computer used by both Weiner, D-New York, and his wife, top Clinton aide Huma Abedin, according to law enforcement officials with knowledge of the inquiry who spoke on the condition of anonymity.

The correspondence included emails between Abedin and Clinton, according to a law enforcement official.

Federal officials have been examining sexually suggestive online messages that Weiner allegedly exchanged with a teenage girl. The link to the Weiner investigation was first reported by the New York Times.

Comey’s announcement appears to resume the FBI’s probe of Clinton’s server, which previously ended in July with no charges.

The announcement could reshape a presidential race that Clinton, the Democratic nominee, has been leading in most public polls. It was immediately hailed by Republican nominee Donald Trump, who told supporters at a New Hampshire rally that “perhaps, finally, justice will be done.” The crowd responded with pumped fists and chants of “Lock her up! Lock her up!”

Clinton told reporters Friday night in Iowa that she learned of the newly discovered emails only after the letter to Congress was made public.

“I’m confident whatever (the emails) are will not change the conclusion reached in July,” she said. “Therefore, it’s imperative that the bureau explain this issue in question, whatever it is, without any delay.”

Asked about the connection to Weiner, Clinton said: “We’ve heard these rumors. We don’t know what to believe.”

Clinton campaign chairman John Podesta called it “extraordinary that we would see something like this just 11 days out from a presidential election.”

Officials familiar with the inquiry said it was too early to assess the significance of the newly discovered emails. It is possible, they said, that some or all of the correspondence is duplicative of the emails that were already turned over and examined by the FBI.

Comey made a similar point in his letter, sent to congressional committee chairmen, saying that the FBI “cannot yet assess whether or not this material may be significant.”

The letter, which was three paragraphs long, contained few details.

He wrote that the FBI, in connection with an “unrelated case,” had recently “learned of the existence of emails that appear to be pertinent to the Clinton investigation.”

Comey wrote that he was briefed on the new material Thursday. “I agreed that the FBI should take appropriate investigative steps designed to allow investigators to review these emails to determine whether they contain classified information, as well as to assess their importance to our investigation,” he wrote.

An FBI spokesman on Friday declined to elaborate, and a spokesman for Attorney General Loretta Lynch declined to comment.

Comey provided no details about the unrelated case that resulted in the discovery of the new emails.

The official said that Comey, once told about the find, felt an obligation to inform Congress, since he had previously told lawmakers that the investigation had been completed.

Abedin, who has worked for Clinton since the 1990s, is vice chairman of Clinton’s presidential campaign. She exchanged thousands of emails with Clinton while serving as her deputy chief of staff at the State Department. She, like Clinton, used an email address routed through the private server.

Neither Weiner nor an attorney for Abedin responded to requests for comment.

Weiner, who represented a New York City congressional district, resigned from his House seat in 2011 after he accidentally tweeted an explicit photo of himself that he had intended to send to a supporter.

Abedin and Weiner were married in 2010, with former President Bill Clinton officiating. Abedin announced this past August that she was separating from Weiner following a report in the New York Post about another sexting incident.

The federal inquiry into Weiner’s contact with the teenager was sparked by a September report in the Daily Mail tabloid.

When Comey announced the FBI’s findings in July, he said that Clinton had been “extremely careless” in her handling of classified material, which was found among the emails exchanged on her private server.

He said then that his investigators had found evidence of potential violation of laws governing the handling of classified information.

But he said “no reasonable prosecutor” would bring charges because investigators had not found evidence that there had been intentional mishandling of classified material, or indications of disloyalty to the United States or efforts to obstruct justice.

Comey had come under enormous pressure from Republicans for his recommendation to bring no case against Clinton. Trump has repeatedly cited the decision as a sign of corruption endemic to Washington institutions and has promised that, if elected, he would reopen the investigation.

Podesta on Friday cited the political pressure on Comey in questioning the director’s actions, saying that Republicans had been “browbeating” career FBI officials “to revisit their conclusion in a desperate attempt to harm Hillary Clinton’s presidential campaign.”

Democrats said Friday that the lack of detail from the FBI allowed Republicans to mischaracterize its actions. Clinton campaign spokesman Brian Fallon told CNN that Comey was “unleashing a wildfire of innuendo.”

The top Democrat on the Senate Intelligence Committee, Sen. Dianne Feinstein (California), issued a blistering statement Friday expressing shock at the FBI’s vague announcement, which she said “played right into the political campaign of Donald Trump.”

“The FBI has a history of extreme caution near Election Day so as not to influence the results,” she said. “Today’s break from that tradition is appalling.”

Some lawmakers saw the announcement as a potential game-changer for the election.

“A total bombshell,” said Rep. Peter King, R-New York, a member of the House Homeland Security Committee. King predicted that the FBI would not close its inquiry before the election and said he believed that Comey wanted the public to know of his move regardless of the outcome.

“He wants it all out there,” King said.

But there was confusion about the FBI’s announcement and immediate calls from lawmakers in both parties for additional information.

Sen. Charles Grassley, R-Iowa, chairman of the Senate Judiciary Committee and a frequent Clinton critic, called the letter “unsolicited and, quite honestly, surprising.”

“Congress and the public deserve more context to properly assess what evidence the FBI has discovered and what it plans to do with it,” Grassley said.

Clinton’s campaign has been bedeviled by the email controversy since before its formal launch in April 2015.

Hacked emails released in recent days by the anti-secrecy group WikiLeaks show that even some of her closest campaign aides were surprised by her use of the server and frustrated by her response, including her slowness to apologize.

“Did you have any idea of the depth of this story?” Podesta asked campaign manager Robby Mook late on March 2, 2015, the day the New York Times revealed that Clinton had exclusively used a private account as secretary.

“Nope,” Mook replied early the next day. “We brought up the existence of emails in 1/8research3/8 this summer but were told that everything was taken care of.”

Polls show that the issue has hurt Clinton politically. A Washington Post-ABC News poll last month found that more than 6 in 10 Americans did not approve of the way Clinton had been handling questions about her email setup.

The State Department’s deputy spokesman, Mark Toner, said the FBI has not notified the department of the new emails, and he referred all questions to the bureau.

“We stand ready to cooperate if we’re asked to do so,” he told reporters. “But I don’t have any additional details at this point.”