Militants killed 25 policemen on Monday in the deadliest attack of its kind in years, as Egypt's army-installed rulers escalated a campaign to crush ousted president Mohamed Morsi's Muslim Brotherhood.
The assailants fired rocket-propelled grenades at two buses carrying police in the Sinai Peninsula, sources said, just hours after 37 Brotherhood prisoners died in police custody.
The incidents came after Egypt's military chief vowed a "forceful" response to violence roiling the Arab world's most populous nation.
The Sinai attack raised fears of a return to the wave of deadly Islamist violence that swept the country in the 1990s.
Egypt is struggling to put a lid on a deep political crisis and violence that has killed almost 800 people in several days of clashes between Islamist protesters and security forces across the country.
Western countries have condemned the violence and are threatening to cut off billions of dollars in aid to Egypt in response, but Saudi Arabia said on Monday that Arab nations are ready to step in to fill the financial void.
The developments came as judicial sources said former autocratic president Hosni Mubarak, who was toppled in a popular uprising in 2011, was granted conditional release in one case against him, but that he would remain in custody in an additional case.
Morsi loyalists vowed new demonstrations on Monday, although a day earlier they had cancelled some marches citing security concerns.
The interior ministry said 25 policeman were killed and two injured in the Sinai attack, which it on "armed terrorist groups."
A border official said afterwards that the Rafah crossing with the Palestinian Gaza Strip, near where the attack occurred, would be closed.
Security sources said another policemen was killed in the northern city of El-Arish, bringing to at least 75 the number of security force members killed in the Sinai since the army deposed Morsi on July 3.
The security situation in the Sinai has deteriorated sharply in the past weeks, with near daily attacks by militants targeting police and military installations.
Elsewhere bloodshed sparked by the August 14 security force crackdown on pro-Morsi protest camps in Cairo showed little sign of abating.
Authorities said 36 Islamist detainees died after police fired tear gas in a bid to free an officer taken hostage by prisoners, as the inmates were being transferred to a north Cairo jail.
But the Brotherhood, the once-banned movement from which Morsi hailed, held the police accountable.
"The murder of 35 detained anti-coup protesters affirms the intentional violence aimed at opponents of the coup, and the cold-blooded killing of which they are targets," it said in a statement in English.
Only hours before the deaths, military chief Abdel Fattah al-Sisi warned security forces would confront any violence from protesters.
"We will never be silent in the face of the destruction of the country," said Sisi, who overthrew Morsi last month after mass protests against the Islamist president's rule. He pledged a "forceful" response to further attacks on police and government buildings.
According to an AFP tally, more than 1,000 people have been killed since mass demonstrations against Morsi erupted at the end of June.
In response to the violence, EU ambassadors were recalled from their summer break for a meeting in Brussels Monday, with foreign ministers due to review the bloc's ties with Egypt at an emergency meeting on Wednesday.
The European Union has pledged nearly five billion euros ($6.7 billion) in aid to Egypt but has cautioned this was under "constant review" after Morsi's ouster.
The United States has cancelled joint military exercises with Egypt.
It has but stopped short of suspending $1.3 billion in annual aid, although some US lawmakers called Sunday for the funds to be cut.
But the international response has not been uniformly critical. Both Saudi Arabia and Jordan have said they back Egypt in its fight against "terrorism".
Egypt's foreign minister Nabil Fahmy said Monday in Sudan that his country was on the "right path".
Israel, meanwhile, an official urged the West to support Egypt's military.
"The name of the game right now is not democracy," he told the Jerusalem Post.
"The name of the game is that there needs to be a functioning state. After you put Egypt back on track, then (you can) talk about restarting the democratic process there."