President Obama’s strategy to “degrade and ultimately destroy” ISIS has become the target of heated criticism, not only from partisan opponents but from many of his supporters as well. Categorically ruling out American boots on the ground, while subcontracting the bloody job of house-to-house fighting to the Iraqi military, Free Syrian Army, and Kurdish Peshmerga, can only assure failure, critics argue.

These assessments fall into a familiar trap: assuming that what has been announced is the sum of the matter. Especially for admirers of the diplomatic sleights of hand practiced by Henry Kissinger or Jim Baker, neglecting the obvious when assessing the current strategy is unfair.

Americans know, as the saying goes, that politics makes strange bedfellows. Most forget, however, that wars can produce even more perverse partners. Facing Hitler’s Germany in World War II, what did the U.S. and Britain do? They allied with Stalin’s Communist Soviet Union. As British Prime Minister Winston Churchill explained, against Hitler he would make a pact with the Devil.

Is the U.S. now counting on devils to help defeat ISIS? The answer is unquestionably yes.

Brute facts are hard to deny. Unstated, and perhaps unstateable, is the expectation among U.S. officials that two of America’s leading adversaries—Bashar al-Assad’s Syria and Iran—will intensify their war against ISIS. Neither Assad nor Iran is fighting as a favor to the United States. Both rightly see ISIS as an imminent or even existential threat to themselves. As uncomfortable as it may be to say, it is Iran-affiliated fighters who are doing the most to kill ISIS militants on the ground in Iraq and Syria at this point.

Because Iran and Syria are declared and deadly enemies of America and its Sunni allies, Washington’s formal acknowledgement of their role in the conflict would be undiplomatic. But assessing the U.S. campaign’s prospects of success without recognizing the work each country is doing is nonsense.

Is the U.S. now counting on devils to help defeat ISIS? The answer is unquestionably yes.

In Syria, Iran is the biggest supporter of Assad’s army, providing his regime with weapons, intelligence, advisors, money, and shock troops from Iran’s proxy, Lebanese Hezbollah. Who are the primary beneficiaries of the airstrikes the U.S. has conducted on targets in Syria? It is no accident that Assad’s foreign minister said his government is “satisfied” with the strikes, while the loudestobjections have come from Assad’s leading opponents, including the Free Syrian Army, which the U.S. has supported with weapons and training.

Last week’s U.S. airdrop of weapons to Kurdish fighters in Kobani, Syria, exemplifies these contradictions. America is currently arming Kurdish fighters affiliated with the PKK, a group the U.S. has for the past decade condemned as a terrorist organization. In attempting to explain this anomaly, Secretary of State John Kerry said, “While they are an offshoot group of the folks that our friends, the Turks, oppose—they are valiantly fighting ISIL.”

In Iraq, the reality is even more convoluted. When ISIS’s advance threatened the Kurdish capital of Erbil, who was first to come to the rescue? Some readers will be shocked to learn that the answer is Iran. Last August, before the ISIS threat appeared on many Americans’ radar, Kurdish President Massoud Barzani held a joint press conference with Iran’s foreign minister to acknowledge Tehran’s contributions and express his thanks. “The Islamic Republic of Iran was the first state to help us,” he announced.

(Related: Iran Says the West Should Step Aside in the Fight Against ISIL)

Who is guarding Iraq’s two holiest Shiite cities, Karbala and Najaf? Units of Iran’s Islamic Revolutionary Guard Corps. As ISIS overran Mosul, Tikrit, and Samarra and drove toward Baghdad, who was the first to assist the Iraqi government? Again, Iran—13 weeks before U.S. airstrikes began near Baghdad.

The most potent military advisor to groups directly fighting ISIS on the ground is the shadowy commander of the Quds Force, Iran’s elite special-operations organization. That same commander,Qassem Suleimani, was responsible for so many American combat deaths during the Iraq War that U.S. officials described him as the personification of evil. Suleimani—who has directed the defense of Erbil, Amerli, and Baghdad in this war—controls Iraq’s three most powerful Shiite militias (Asaib Ahl al-Haq, Kataib Hizballah, and Badr Corps), at least three battalions of Iranian special forces, and an open pipeline of sophisticated weapons.

History has repeatedly reminded us that short-term necessity can fuel new long-term dangers. When ISIS is driven from Iraq, the Shiite militias that have cleared and held territory will not readily relinquish control to others. As a recent Amnesty International report notes, many of these Shiite militias have committed the same types of brutality exhibited by ISIS. Will Iraq’s Shiite-majority south turn into Iraq’s equivalent of Iranian-affiliated Hezbollah in Lebanon? And if the Kurdish Peshmerga and Sunni tribal forces succeed with outside help in eventually expelling ISIS, will they be willing to hand over the keys to a Shiite-controlled government in Baghdad? With these challenges in mind, while doing whatever is required to defeat ISIS, we should be realistic about the potentially dark consequences that may follow.

In the months ahead, Obama hopes to persuade Turkey and our Sunni Arab allies (including Saudi Arabia, the U.A.E., and Jordan) to contribute combat forces and funds to the campaign against ISIS; to reconstitute serious combat units of the Iraqi army; to reawaken Sunni tribal leaders who played a vital role in the success of the surge in 2007; to strengthen the Peshmerga; and to vet and train at least 5,000 Syrian moderates to fight. Americans should hope that these aspirations will be realized.

But in terms of the urgent task at hand, the good news is that ISIS threatens its immediate neighbors even more than it threatens the United States. However irreconcilable the conflicts between Sunni and Shiite, Saudi Arabia and Iran, Assad and the Syrian rebels, all are high-priority targets on ISIS’shit list. Some of these actors are prepared to fight for their own survival. Intricate, subtle, if not duplicitous statecraft and diplomacy will be essential if Obama’s war against ISIS is to succeed. When it does, this success will be due in no small part to blood spilled by Iranian and Syrian forces whose role we need not acknowledge or reward, but cannot deny.