U.S. special operations forces captured a militant in Libya accused of playing an instrumental role in the Benghazi attacks, officials said Monday, in a high-stakes operation designed to bring the perpetrators to justice five years after the deadly violence.

President Donald Trump identified the militant as Mustafa al-Imam and said his capture signified that the four Americans who died "will never be forgotten." Justice Department officials were escorting al-Imam by military plane to the United States, where he's expected to be tried in federal court.

"Our memory is deep and our reach is long, and we will not rest in our efforts to find and bring the perpetrators of the heinous attacks in Benghazi to justice," Trump said.

The Navy SEAL-led raid marked the first publicly known operation since Trump took office to target those accused of involvement in Benghazi, which mushroomed into a multiyear political fracas centered on Republican allegations of a bungled Obama administration response. Those critiques shadowed Hillary Clinton, who was secretary of state at the time of the attacks, through her presidential campaign.

U.S. forces captured al-Imam just before midnight local time Sunday in Misrata, on Libya's north coast, U.S. officials said. He was taken to a U.S. Navy ship at the Misrata port for transport by military plane to Washington, where he's expected to arrive within the next two days, one of the officials said.

Once on American soil, al-Imam will face trial in U.S. District Court for the District of Columbia as the FBI continues to investigate, the Justice Department said. He faces three criminal charges that were filed in May 2015 but only recently unsealed: killing or conspiring to kill someone during an attack on a federal facility, providing support for terrorists, and using a firearm in connection with a violent crime.

It wasn't immediately clear how al-Imam was involved in the Sept. 11, 2012, violence. The U.S. attorney's office said he is a Libyan national and about 46 years old.

Trump said he'd ordered the raid, and thanked the U.S. military, intelligence agencies and prosecutors for tracking al-Imam and enabling his capture. The U.S. officials said the operation was coordinated with Libya's internationally recognized government. They weren't authorized to speak publicly on the matter and demanded anonymity.

Secretary of State Rex Tillerson said he'd spoken with the relatives of some of the Americans who died in Benghazi: U.S. Ambassador Chris Stevens, State Department information management officer Sean Patrick Smith, and contract security officers Tyrone Woods and Glen Doherty. Tillerson said the U.S. would "spare no effort" to ensure al-Imam is held accountable.

Al-Imam will face court proceedings in U.S. District Court, officials said, in an apparent departure from Trump's previously expressed desire to send militants to the U.S. detention center at Guantanamo Bay, Cuba.

In an interview last March with conservative radio host Hugh Hewitt, Attorney General Jeff Sessions called Guantanamo "a very fine place for holding these kind of dangerous criminals."

The commando raid also came amid an ongoing debate about the use of U.S. forces to pursue insurgents in Africa and other locations outside of warzones like Iraq and Afghanistan. Four U.S. soldiers were killed in an ambush in Niger earlier this month under circumstances that have remained hazy and prompted Democrats and Republicans in Congress to express concerns.

Earlier this month, another man accused in the Benghazi attack, Abu Khattala, went on trial in federal court in Washington. Khattala, captured during President Barack Obama's tenure, has pleaded not guilty to the 18 charges against him, including murder of an internationally protected person, providing material support to terrorists and destroying U.S. property while causing death.

The Benghazi assault started in the evening when armed attackers scaled the wall of the diplomatic post and moved through the front gate. Stevens was rushed to a fortified "safe room" along with Smith, but were then siphoned off from security officers when attackers set the building and its furniture on fire. Libyan civilians found Stevens hours later in the wreckage, and he died of smoke inhalation in a hospital, becoming the first U.S. ambassador killed in the line of duty in more than three decades.

A nearby CIA annex was attacked by mortar fire hours after the diplomatic complex, killing Woods and Doherty, who were defending the rooftop.

The attack became fodder for multiple congressional investigations to determine what happened and whether the Obama administration misled the public on the details of the bloody assault. Initial accounts provided by administration officials, notably Obama's U.N. ambassador, Susan Rice, said the attack grew out of a protest against an anti-Muslim internet film. Later, the administration said it was a planned terrorist attack.

A two-year investigation by a House Benghazi committee focused heavily on Clinton's role and whether security at the compounds and the response to the attack was sufficient. It was the Benghazi probe that revealed Clinton used a private email server for government work, prompting an FBI investigation that proved to be an albatross for her presidential campaign.

___

Associated Press writers Maggie Michael and Sadie Gurman contributed to this report.