NAIROBI, Kenya (AP) — A lone gunman entered a military base in Somalia and killed at least three Kenyan peacekeepers Monday, the latest attack by extremist fighters who oppose the presence of foreigners in the Horn of Africa nation, according to Kenya’s military.

The gunman fired his rifle indiscriminately, wounding five other soldiers before he was gunned down, said a Kenyan military official who requested anonymity because he was not yet authorized to reveal the information.

The attack on Monday morning took place at the Sarira Forward Operating Base in the Lower Jubba region of southern Somalia near the border with Kenya.

Al-Shabab through its media confirmed it had carried out the attack.

“We believe the lone wolf was testing the ground for more such incidents. We must be more careful and vigilant,” said the Kenyan military official. “As we near the festivities, we need to be very vigilant of our surroundings. The terror threat is still rife and all measures should be taken to tame any plan.”

Kenyan authorities also are urging vigilance after the start of the soccer World Cup in Qatar. In 2010, at least 76 people were killed when al-Shabab targeted a rugby club and a restaurant in the Ugandan capital, Kampala, where customers were watching the World Cup final on giant screens.

“It is at this time the militants know we might let our guard down as we watch” the World Cup, the official said.

Kenyan troops, who are deployed to Somalia under the banner of the African Union, are active along the border with Somalia. Peacekeepers from Burundi and Uganda are based in or near the Somali capital of Mogadishu, the seat of the federal government.

In recent years, al-Shabab fighters have launched cross-border attacks, especially in the remote Kenyan counties of Mandera and Garissa, after breaching security zones.

The attacks have killed or wounded dozens of civilians and security personnel. On Sunday gunmen believed to be from al-Shabab attacked a police post in Mandera before being repulsed.

___

Faruk reported from Mogadishu, Somalia.