No one can look at photographs of Tuesday’s scene at Jerusalem’s Har Nof synagogue without shuddering. The sight of prayer shawls and prayer books drenched in blood stirs the bitterest memories. They are the images of a pogrom. Reports of the event confirm that impression. The murmuring hush of morning worship was broken by what witnesses say was a frenzied attack, the two Palestinian assailants – cousins from East Jerusalem – lashing out with weapons that included guns, knives and a meat cleaver. The floor of a house of prayer was turned red.

People of all faiths – and even of none – will find something especially appalling about this act of violence. Any place of worship is meant to be a sanctuary; that much is understood universally. Inevitably, however, this attack has struck a particular and deep nerve in the Israeli – and Jewish – psyche. Attacks like this were precisely what the creation of the state of Israel was meant to prevent. Israel was to be the one place in the world where Jews could pray in peace and safety. Synagogues in London, Paris or New York have grown used to having a security presence on the door. Now there are calls for the same precaution to be taken in Israel, a bleak thought for a country established to be a safe haven.

Not much less depressing has been the reaction from key Palestinian voices. Though it seems the killers were acting on their own initiative rather than under any official direction, Hamas praised the killings as a “quality development”. The PFLP faction called the murders “heroic”, while there were reports of sweets being distributed to the children of Gaza in celebration. The admirable exception to all this was the Palestinian president, Mahmoud Abbas, who was swift to condemn the attack on “Jewish worshippers in their place of prayer”. The president’s message nevertheless grated on the ears of those Israelis who believe the Palestinian Authority has been guilty of “incitement” and who cite Abbas’s own recent warning that Jewish settlers were set to enter and “defile” the al-Aqsa mosque.

The fear, then, is that what has long been a bitter and bloody territorial conflict will escalate into something even more intractable: a holy war. By attacking men as they pray – not, it is worth stressing, in the occupied West Bank or in annexed East Jerusalem but inside the boundaries of pre-1967 Israel proper – Tuesday’s killers risk turning the conflict of Palestinian against Israeli into a battle of Muslim against Jew. Israel’s justice minister, Tzipi Livni, was right to say that such a war is to be dreaded – because “a religious war cannot be solved”.

The related fear is that Jerusalem becomes the frontline in such a battle. It would mean a confrontation played out street by street, even hand to hand, if the brutality witnessed on Tuesday were to be repeated. The status quo that has, not without strain, kept the peace in the holy sites – the area known to Jews as the Temple Mount and to Muslims as Haram al-Sharif – could unravel.

For the moment, these are just fears. There is nothing inevitable about their realisation. But it will require political leadership. On the Palestinian side, if media controlled by the Palestinian Authority are guilty of incendiary incitement then it should stop. As for Hamas, this newspaper has long believed that organisation will, eventually, have to be included in any process of negotiation. But Hamas hardly makes that case easier to argue when it speaks as it did on Tuesday – and when its officials still struggle to speak about Israel without resorting to traditional anti-Jewish caricature. Last week one of its spokesmen suggested Israelis had manipulated the media to bring about the downfall of communism.

But the burden on Israel is heavy too. Binyamin Netanyahu has failed to show Palestinians any kind of political horizon. He shows them no route by which they might reach independence or even an end to occupation. In the absence of such a political path, the men of violence prosper.

It is true that Netanyahu is surrounded by cabinet hardliners who would go further than he would, annexing large swaths of the West Bank tomorrow. But he needs to think beyond the mere maintaining of his coalition and his own job. He needs to lead, and point the way out of a situation that is intolerable – and lethally dangerous – to both peoples.