The US president says he is worried Yemen is drawing foreign terrorists who once may have gone to Pakistan's border, after a suicide bomber killed more than 90 soldiers in Sanaa.

The US is worried Yemen is drawing terrorists and extremists who once may have fought NATO forces in Afghanistan, US President Barack Obama said

"We are going to continue to work with Yemeni government to try to identify AQAP (Al-Qaeda in the Arabian Peninsula) leadership and operations and try to thwart them," US President Barack Obama said.

"That's important for US safety and it's also important for stability of Yemen and for the region," he added.

The suicide bomb attack came as Nato leaders met on Monday and endorsed Mr Obama's exit plan from Afghanistan after nearly 11 years. The plan involves leaving Afghan security forces in the leading combat role by summer 2013.

Despite US-backed political progress in Yemen, the country remains poor, unstable and at risk of further attacks. A suicide bomber in an army uniform killed 96 soldiers on Monday at a military parade rehearsal in the capital. Resident held a vigil after sunset (see photo, left).

Al-Qaeda's Yemen branch claimed responsibility for the attack by email, saying the bombing was revenge for a US-backed offensive against al-Qaeda in southern Yemen. The attack is the worst since February when President Mansour Hadi assumed power. He pledged to eradicate al-Qaeda rebels in the country. The attack also follows a 10-day army offensive against al-Qaeda in Yemen's southern Abyan province.

'We will win, whatever the sacrifices'

A statement in Mr Hadi's name read on state TV said: "The war on terrorism will continue until we win, whatever the sacrifices are."

"We are speeding up the restructuring of the army to bring back stability to the country, which was on a brink of all-out war," the statement said.

The bombing wounded more than 200 people, underscoring the threat to Yemen as it battles Islamist militants in the south and threats to shipping lanes in the Gulf of Aden and the Red Sea.

Target: Yemen's defence minister

Al-Qaeda said the bomber was targeting Yemen's defence minister, Major General Mohammed Nasser Ahmed, who arrived minutes before the blast. He was not injured.

Mr Obama, speaking to reporters, also briefly mentioned discussions with Pakistan President Asif Ali Zardari in which he emphasised that Pakistan has to be part of the solution in Afghanistan.

A summit of NATO leaders ended without a resolution to the dispute between the US and Pakistan over reopening NATO supply routes through Pakistan into Afghanistan.