A vehicle and the surrounding area were engulfed in flames inside the U.S. compound in Benghazi, Libya, late on Sept. 11, 2012. (STR/AFP/Getty Images)

U.S. officials suspect that a former Guantanamo Bay detainee played a role in the attack on the American diplomatic compound in Benghazi, Libya, and are planning to designate the group he leads as a foreign terrorist organization, according to officials familiar with the plans.

Militiamen under the command of Abu Sufian bin Qumu, the leader of Ansar al-Sharia in the Libyan city of Darnah, participated in the attack that killed U.S. Ambassador J. Christopher Stevens and three other Americans, U.S. officials said.

Witnesses have told American officials that Qumu’s men were in Benghazi before the attack on Sept. 11, 2012, according to the officials. It’s unclear whether they were there as part of a planned attack or out of happenstance. The drive from Darnah to Benghazi takes several hours.

The State Department is expected to tie Qumu’s group to the Benghazi attack when it designates three branches of Ansar al-Sharia, in Darnah, Benghazi and Tunisia, as foreign terrorist organizations in the coming days.

In 2007, Qumu was released from the U.S. prison at Guantanamo Bay, Cuba, and sent to Libya, where he was detained. The Libyan government released him in 2008.

He and two other men, militia leaders Ahmed Abu Khattala and Seif Allah bin Hassine, will be identified as “specially designated global terrorists,” a determination that allows U.S. officials to freeze their financial assets and bar American citizens and companies from doing business with them.

The officials spoke on the condition of anonymity because they were not authorized to publicly discuss the developments.

About a dozen criminal complaints have been filed in the Benghazi case, with more expected. U.S. intelligence officials have said that several militias had a hand in the attack. Some of the individuals charged are from Darnah, although it’s not clear if they are tied to Qumu’s group. Khattala has already been named in a criminal complaint.

The FBI declined to comment Tuesday.

U.S. officials are also investigating whether any of the people involved in the Benghazi raid had a role in the killing of Ronnie Smith, an American schoolteacher who was gunned down while jogging in the city last month.

Lawless conditions in eastern Libya have frustrated U.S. efforts to investigate the attack in Benghazi and capture those responsible. U.S. officials scrapped a plan to snatch Khattala in Benghazi for fear that American action could trigger unrest and destabilize the Libyan government.

Khattala, meanwhile, has flaunted his freedom, giving interviews to U.S. reporters as the FBI watches from afar. He has denied any involvement in the attack.

Qumu, 54, a Libyan from Darnah, is well known to U.S. intelligence officials. A former tank driver in the Libyan army, he served 10 years in prison in the country before fleeing to Egypt and then to Afghanistan.

According to U.S. military files disclosed by the anti-secrecy group WikiLeaks, Qumu trained in 1993 at one of Osama bin Laden’s terrorist camps in Afghanistan and later worked for a bin Laden company in Sudan, where the al-Qaeda leader lived for three years.

Qumu fought alongside the Taliban against the United States in Afghanistan; he then fled to Pakistan and was later arrested in Peshawar. He was turned over to the United States and held at Guantanamo Bay.

He has a “long-term association with Islamic extremist jihad and members of al-Qaida and other extremist groups,” according to the military files. “Detainee’s alias is found on a list of probable al-Qaida personnel receiving monthly stipends.”

Qumu also had links to Zayn al-Abidin Muhammed Hussein, known by his alias Abu Zubaida, a key al-Qaeda facilitator who is being held indefinitely at Guantanamo.

The United States is offering $10 million for information about the Benghazi attack.

The day before the raid, anti-American violence erupted in the Middle East, North Africa and elsewhere when al-Qaeda leader Ayman al-Zawahiri called on followers to avenge the death of Abu Yahya al-Libi, the terrorist group’s No. 2, who was killed in a CIA drone strike. Officials, however, said there is no evidence that al-Qaeda’s core leadership was directly tied to the assault on the compound in Benghazi.

“The situation on Sept. 11th in Benghazi was a complicated one,” a senior administration official said. “We will never be able to know what motivated everyone involved in this attack, and one of the things the investigation is looking at right now is the level of planning that may have gone into it.”

In addition to Qumu and Khattala, American officials are eager to question Faraj al Chalabi, a Libyan extremist who might have fled the country.

Julie Tate contributed to this report.