Militants carried out a multi-stage attack on Yemen’s Defense Ministry early Thursday and clashed with government forces in the fortified compound throughout the day, leaving at least 52 people dead and scores injured, the government said.

The assault was the most ambitious in the capital, Sanaa, since May 2012, when al-Qaeda in the Arabian Peninsula (AQAP), a local offshoot of the global terrorist network, targeted a military parade with a suicide bombing that killed more than 90 soldiers. Although many observers here said they suspected AQAP was behind the latest violence, it remained unclear late Thursday exactly who was responsible or why the assault occurred.

Yemen’s Supreme Security Committee said in a statement that at least 167 people were injured in Thursday’s attack, which began just after 9 a.m. when a car bomb exploded outside the Defense Ministry’s western gate, shattering windows in nearby building and shaking panes across the city.

The blast was followed shortly afterward by another and then by the arrival of a number of gunmen — some dressed in military uniforms, according to witnesses — who stormed a military hospital in the complex and opened fire on doctors, nurses, patients and others inside. State news media reported that the victims included two German doctors, two Vietnamese doctors, two Filipino nurses, an Indian nurse and a Yemeni female doctor.

“The target was the hospital because it’s for Ministry of Defense leaders,” said Mahmoud Shahra, an adviser in the prime minister’s office. “The first [bomb] was a truck, and the second was an ambulance.”

Defense Minister Mohamed Nasser Ahmed, who has been the subject of several assassination attempts in the past, was in Washington for talks with his American counterparts Thursday when the violence erupted in Sanaa.

The Yemeni army sealed off the ministry compound, where the militants remained holed up, according to a defense official who spoke on the condition of anonymity because of the fluidity of the situation. Sporadic, sometimes heavy gunfire could be heard throughout the day, despite several false reports that the battle was over. The sound of machine guns could be heard well into the night.

The assault came amid high political tension and a deteriorating security situation in Yemen. The National Dialogue Conference, which was meant to help the country navigate the post-Arab Spring transition, has stalled, while a restive southern secessionist movement grows impatient and fighting between Houthi rebels and their opponents rages in the country’s north. Just last month, assailants on a motorcycle gunned downed Abdulkareem Jadban, a Houthi member of parliament and a dialogue member, in downtown Sanaa.

“This operation was definitely a terrorist operation. This was a challenge to President Abed Rabbo Mansour Hadi and an attempt to ruin the national dialogue,” said Muhsin Khosroof, a retired colonel who formerly worked at the Defense Ministry complex.

Al-Qaeda has claimed responsibility for numerous attacks in Yemen over the years, including the 2000 bombing of the USS Cole and a 2008 attack on the U.S. Embassy in Sanaa. The Yemeni and Saudi branches of al-Qaeda merged in 2009 to form AQAP, which has been particularly active following the 2011 revolution that ousted Yemeni President Ali Abdullah Saleh.

In recent months, AQAP has struck Yemeni army outposts in Shebwa and Hadramout provinces, in coordinated attacks resembling the one that occurred Thursday in Sanaa.

Among those confirmed dead Thursday was Abduljaleel Noman, a prominent judge and a member of the National Dialogue Conference, his wife and a relative of Hadi’s. Germany’s foreign minister, Guido Westerwelle, confirmed that the two slain Germans were employees of the semi-governmental GIZ aid organization, along with a Yemeni colleague.

“The German government harshly condemns this cowardly attack,” he told reporters in Berlin.

Marie Harf, a U.S. State Department deputy spokeswoman, denounced the assault, as well. “We stand with Yemen against this violence and remain firmly committed to supporting the Yemeni people as they seek to conclude the national dialogue and move forward peacefully with Yemen’s historic democratic transition,” she said.

Despite the tense atmosphere in Sanaa, people started to return to their daily routines as early as midday. On a street near the ministry strewn with broken glass from windows blown out by the explosions, residents seemed surprised by the attack but not alarmed.

“For four hours, there was fighting,” said Ibrahim, a young man who lives nearby. “But don’t worry. It’s Yemen.”