The US military said it carried out an airstrike in Somalia that killed 52 al-Shabaab extremists, in response to an attack on Somali forces.

Al-Shabaab controls large parts of rural southern and central Somalia and continues to carry out high-profile attacks in the capital, Mogadishu, and elsewhere. The group claimed responsibility for the deadly attack on a luxury hotel complex in Nairobi, Kenya on Tuesday.

A US Africa Command statement said the airstrike occurred on Saturday near Jilib in Middle Juba region. The US said Somali forces had come under attack by a “large group” of the al-Qaida-linked extremists.

The statement did not say how many Somali forces were killed or wounded. There were no reports of Americans killed or wounded.

Al-Shabaab asserted via its Shahada news agency that its attack on two Somali army bases killed at least 41 soldiers. It described the location as the Bar Sanjuni area near the port city of Kismayo.

There was no immediate comment from Somalia’s government.

In neighboring Ethiopia, state television cited the defense ministry as saying more than 60 al-Shabaab fighters had been killed and that four vehicles loaded with explosives had been “destroyed”.

Ethiopia contributes troops to a multinational African Union peacekeeping mission in Somalia and has troops there independently under Ethiopian army command.

Al-Shabaab controls large parts of rural southern and central Somalia and continues to carry out high-profile suicide bombings and other attacks in the capital, Mogadishu, and elsewhere.

The US has dramatically stepped up airstrikes against al-Shabaab in Somalia since Donald Trump took office, carrying out at least 47 such strikes last year. Some have targeted top leaders or key financial officials. The extremist group funds its attacks with an extensive network of “taxation” and extortion.

In October, the US said an airstrike killed about 60 fighters near the al-Shabaab-controlled community of Harardere in Mudug province in the central part of the country.

The airstrikes hamper the extremist group but have not “seriously degraded al-Shabaab’s capability to mount strikes either inside or outside Somalia”, Matt Bryden of Sahan Research, an expert on the extremists, said after the Nairobi hotel attack.

Airstrikes alone cannot defeat the extremists, Bryden said, and must be combined with more ground-based attacks as well as a non-military campaign to win over residents of extremist-held areas.

The US on Saturday said it was committed to “preventing al-Shabaab from taking advantage of safe havens from which they can build capacity and attack the people of Somalia”.