In Kenya’s worst attack on security forces in recent memory, dozens of officers fell victim to an ambush in the Suguta Valley Friday night and Saturday morning.

The police had been pursing members of the Turkana tribe, who were accused of stealing cattle from the nearby Samburus. The two ethnic groups are old rivals who often steal livestock from one another, but a cattle raid allegedly carried out by Turkana groups in October killed 13 civilians, according to Kenyan news outlet Capital FM.

As police trailed the suspected perpetrators Friday night, they were outmaneuvered. Turkana gunmen took to a hilltop and fired upon the exposed officers. The search for bodies is still under way.

One anonymous officer told Capital FM that he was helping search for casualties. “We are shocked at what we saw… bodies of police officers lying all over the ground,” he said.

“I have never seen something like this,” he added. “The number of officers killed is now 42.”

Kenya is in the process of selecting a new police inspector general, who will be tasked with cutting down on corruption and working with the government to ensure the efficacy of security forces. After this weekend, the winning candidate (who may be selected from a short list as early as December) will be under pressure to make sure that a tragedy like this never happens again.

Police spokesman Eric Kiraithe, who is under consideration for the inspector general position, said on Monday that the weekend massacre proves that police forces are underequipped and poorly trained.

“The enemy noticed the advance of the deployment and moved up to a hill so the team was receiving fire from a tactical disadvantage,” he explained, according to the Associated Press.

Kiraithe knows the necessary changes will involve much more than better training.

“Corruption in the police force is deep and wide,” he admitted.

In order to be successful, Kenya’s police force will have put aside local loyalties in order to effectively address tribal rivalries that have plagued the country for decades.

Though the problem is longstanding, most communal conflicts were manageable until just a few years ago. The closely fought 2007 presidential election stirred up tensions over ethnic differences, and the country erupted into violence in January 2008.

That presidential race pitted members of the incumbent candidate's Kikiyu tibe, Kenya's largest group that has long been accused of monopolizing political power, against the opposition candidate's Luo tribe.

Incumbent President Mwai Kibaki claimed victory on Dec. 30, 2007, but many protesters claimed electoral fraud and took to the streets. The violence escalated quickly, and clashes eventually killed about 1,500 people. Hundreds of thousands more were displaced.

To quell the uprising, Kibaki’s opponent Raila Odinga later assumed the post of prime minister in a shaky power-sharing agreement that persists to this day.

The next elections will take place in March of 2013, and many fear it could spark a new round of tribal violence. In that context, the cattle raids that led to Saturday’s bloody ambush are cause for concern – especially if police forces are ill-equipped to handle violent incidents.

Also worrisome is an abundance of weapons in Kenya’s north, partly due to unregulated arms trade between communities there and militants in unstable neighboring countries like South Sudan and Somalia. Because official security forces are scarce in these regions, Kenyans often take it upon themselves to defend their properties and livelihoods.

Responding to the weekend violence, Kenya’s National Commission on Human Rights called for better training for national security officials.

"At a time when the country is gearing up for elections, security is one of the most paramount factors that must be guarded and respected for law and order to prevail," it said in a statement, according to the Associated Press.

"It is therefore worrying that such episodes will undermine public confidence in the security sector as the country awaits the appointment of the inspector general of police."

A white Fiat van rammed into pedestrians outside enjoying a late afternoon stroll on Las Ramblas in Barcelona on Thursday killing at least 13 people and leaving hundreds injured. The Islamic State group claimed responsibility for the attack.