A suicide bomber on Monday targeted a military training academy in Somalia, killing 25 soldiers in the capital of Mogadishu, a senior army officer said.

Al-Qaida’s affiliate in East Africa, the Somalia-based al-Shabab, claimed responsibility for the attack.

The officer said more than 40 others were wounded in the bombing at the Jalle Siyad military academy, said the officer. He only his first name, Abdullahi, because he was not authorized to speak publicly. There was no immediate statement from Somali authorities.

BUILDING COLLAPSE IN CAMEROON'S LARGEST CITY CLAIMS OVER 30 LIVES, RESCUE OPERATIONS CONTINUE

Africa Fox News graphic

A deadly suicide bombing at a Somali military academy in Mogadishu has killled 25 soldiers.  (Fox News)

CLICK HERE TO GET THE FOX NEWS APP

Al-Shabab controls parts of rural Somalia and often targets high-profile areas of the capital.

Somali authorities launched a new offensive against al-Shabab last year to try to recapture extremist-held territory and dismantle the taxation and broader financial network that funds the fighters.

Somalia’s military is under growing pressure to assume responsibility for the Horn of Africa country’s security as a multinational African Union force slowly draws down. Partners including the United States, the European Union and Turkey help to train Somali forces.