A US jury has acquitted the Libyan man accused of engineering the 2012 Benghazi attacks of multiple counts of murder — the most serious charges he faced in his trial — but convicted him of several lesser charges, including providing material support to terrorists.

The defendant, Ahmed Abu Khattala, 46, was also convicted of carrying a firearm during a violent crime and maliciously destroying property. He could face up to 60 years in prison.

Khattala is the first person to be convicted on charges related to the attacks on a US diplomatic compound in Libya on September 11, 2012, which resulted in the death of four Americans: US Ambassador to Libya J. Christopher Stevens, State Department Information Management Officer Sean Smith, and CIA security contractors Tyrone Woods and Glen Doherty.

Prosecutors said Khattala was the ringleader behind the band of 20 militants who attacked the US mission in Libya with grenade launchers and machine guns and set it on fire. Stevens and Smith died from smoke inhalation from the fire, and Woods and Doherty were killed by mortar fire during another wave of attacks on a CIA facility nearby.

But during the seven-week trial, prosecutors struggled to provide evidence of Khattala’s exact involvement in the attacks. Khattala apparently did not show up in the compound until after the fighting ended, and there is no clear evidence that he fired a gun or lit a fire. Prosecutors’ case that he was the mastermind behind the attacks relied on the testimony of three Libyan witnesses and cellphone records.

The attack caused a firestorm of controversy for then-President Barack Obama and his Secretary of State Hillary Clinton. Republicans accused Clinton in particular of having ignored the terrorist threat facing the diplomats in Benghazi and of lying to the American people afterward about what had actually happened in the attack. While there is evidence that the Benghazi outpost was poorly protected, no official inquest has found that Clinton was personally responsible for what happened that night.

Responding to the verdict, CIA Director Mike Pompeo said in a statement on Tuesday that “a small measure of justice was meted out."

"It took intelligence to find him, soldiers to assist in capturing him, law enforcement to interview him, and a legal team to put him away," Pompeo said. "Khattala's sentencing is to follow; but no term in prison will bring our people back."

The trial is a reminder of how difficult it can be to prosecute terrorism cases in situations that lack clear and abundant evidence.

A second suspect, Mustafa al-Imam, will also go on trial soon on charges related to the Benghazi attack.