The top leader of an al-Qaida-inspired group in Egypt's restive Sinai and three of his associates were killed in a drive-by shooting in the peninsula on Thursday, senior Egyptian security officials said.

The development deals a heavy blow to the militant group, which has claimed scores of deadly attacks across Egypt since the ouster of Islamist President Mohammed Morsi last July. It is also a boost for Egypt's military-backed authorities ahead of the country's presidential elections next week.

According to three senior security officials, Shadi el-Manaei, who headed Ansar Beit al-Maqdis — or the Champions of Jerusalem as the group is also known — and the three other militants were found dead after unidentified gunmen sprayed their vehicle with bullets on a road in central Sinai.

The officials said that according to the police investigation, 15 men in vehicles and armed with automatic machineguns, attacked el-Manaei's car to avenge the killings of tribesmen by his terror group.

The tribesmen were killed after the militants claimed they had cooperated with police against Ansar Beit al-Maqdis. The officials spoke on condition of anonymity because they were not authorized to talk to the media.

Ansar Beit al-Maqdis first arose in Sinai, where for years militant groups largely made of up local Bedouin had carried out attacks, lobbing rockets into neighboring Israel and opening fire on soldiers and police officers. Attacks escalated after the 2011 fall of autocrat Hosni Mubarak, but increased dramatically after Morsi's overthrow at the hands of the military.

The group claimed responsibility for the suicide car bombing targeting Egypt's interior minister in September, an attack he escaped from unharmed. Scores of Egyptian police officers and soldiers have been killed in attacks by suspected Islamic militants since. El-Manaei, the mastermind behind the group's attacks, has long been on the run.

Egypt's military-backed interim government has blamed Morsi's Muslim Brotherhood group for the violence, outlawing it and calling it a terrorist organization. But the Brotherhood denies being involved in the violence.

The United States has designated Ansar Beit al-Maqdis a foreign terrorist organization.