Catastrophe is a good word to describe what is happening in Iraq and the Middle East, and there is no simple or immediate response from the United States that would seem to be a remedy.

This week, jihadi fighters from the extremist group known as the Islamic State of Iraq and Syria moved with shocking speed to seize Mosul, Iraq’s second-largest city. They had already captured Fallujah, where American forces had fought a vicious battle during the Iraq War, and were moving on other major cities, including Baghdad.

This insurgent force includes Baathist military officers who served under Saddam Hussein, plus insurgents from Syria and other extremists. In other words, the regime of Iraqi Prime Minister Nouri al-Maliki is in danger of falling to the Baathist Sunni forces ousted by the U.S. invasion of 2003.

Al-Maliki has come in for severe criticism from the Obama administration for governing as a narrowly sectarian leader, favoring his fellow Shias and excluding the Sunni minority from power. Now the failure of his military to defend Iraq has called into question whether the Iraqi government can even survive. Al-Maliki has sought air support from the Obama administration, according to The New York Times, but President Obama has rebuffed him. With the fall of Mosul, from which half a million refugees have fled in the last few days, the administration will have to rethink its views.

The insurgency in Iraq is part of the regionwide insurgency that also threatens Bashar Assad of Syria. Thus, Syria and Iraq are engulfed in what could become a cataclysmic civil war between Sunni and Shia peoples. The United States has supported Sunni insurgents seeking to topple Assad, whose sect is related to Shiism, but also supports the Shia al-Maliki in Iraq. Behind all these shadow puppets lurk the major powers of Shia Iran and Sunni Saudi Arabia, as well as one of our NATO allies, Turkey.

The Obama administration has been criticized for failing to arm the moderate insurgents in Syria, who, it is argued, could have blunted the emergence of the extremist al-Qaida-linked faction that now threatens Iraq. Yet Obama never had confidence that the so-called moderates could keep sophisticated weapons out of the hands of extremists. The call has now sounded again for the United States to intervene with military aid to help moderates who can take on the jihadis now threatening Iraq. What a mess. Who are the good guys?

The U.S. frequently entertains the notion that “moderate” rebels represent the most palatable option during an insurgency. The trouble is that, going back to the Russian Revolution, it is often the most extreme and ruthless who are able to prevail in times of trouble. Thus, the moderate, urban, liberal forces in the Middle East who inaugurated the Arab Spring have given way to religious extremists or military strongmen.

The situation in the Middle East after the fall of Mosul would seem to be extremely fluid. Turkey may get involved. In Syria, the U.S. favors the insurgency, but only some of the insurgents. In Iraq, the U.S. favors the government. The U.S. is seeking a rapprochement with Iran; meanwhile, Iran is a supporter of Assad of Syria (our enemy) and of al-Maliki in Iraq (our friend, sort of).

Obama has tried to extricate the U.S. from Iraq, but it is likely now he will be looking to back someone capable of taking on the jihadis who now threaten Iraq and who are also hijacking the Syrian insurgency. Who will that be? Turkey? A regional war would be the catastrophe we have been seeking to avoid throughout this unstable period.

In fact, Iran may hold the key. Security for the Shia regimes against extremist Sunni forces is in everyone’s interests, even if Saudi Arabia thinks otherwise. Iran may recognize that that means Assad in Syria has to go, in favor of a leader acceptable to moderate insurgents. Can Obama negotiate these turbulent waters, which have so many strategic and moral hazards? For the sake of peace in a war-ravaged region, we hope so.