While the Trump administration celebrates a new deal meant to freeze the battlefield in southern Syria, the Assad regime and Iran are preparing for the next phase of the long-running war, in which they will attempt to conquer the rest of the country. Whether Iran succeeds depends largely on whether the United States acknowledges and then counters that strategy.

Tehran is pouring thousands of fighters into newly acquired territories and building military bases. Although U.S.-supported forces hold territories east of the Euphrates River in Syria’s southeast, as well as along the borders of Israel and Jordan in the southwest, Iran has stated its intention to help Bashar al-Assad retake all of Syria.

Iranian Revolutionary Guard Corps commander Maj. Gen. Qasem Soleimani has been recently spotted in the eastern Syrian city of Deir al-Zour, showing how high a priority it is for Iran to take the oil-rich land nearby. Soleimani has also been spotted near the town of Abu Kamal, which sits just across the border from the Iraqi city of Qaim and is the last piece of the land bridge Iran seeks to establish from Tehran to Beirut.

The agreement President Trump struck with Vladimir Putin in Asia was sold as a way to ensure that the liberated areas of Syria stay out of Assad’s control and to provide for the exit of foreign fighters. But Russian Foreign Minister Sergei Lavrov said Moscow has no intention of pushing Iran to remove its troops from Syria.

So what can be done? A task force of senior former U.S. diplomatic and military officials has come up with suggestions for how Trump could prevent Iran from taking over what’s left of liberated Syria and fulfill his own promise to contain Iranian influence in the region.

“Most urgently . . . the United States must impose real obstacles to Tehran’s pursuit of total victory by the Assad regime in Syria,” the report by the Jewish Institute for National Security of America states. “Time is of the essence.”

First, the United States needs to declare a clear Syria policy that removes suspicions that the United States is going to pull up stakes now that the Islamic State caliphate has fallen. The policy should make clear that a U.S. military presence will remain on the ground and in the air, to ensure that the Islamic State doesn’t reemerge and Assad doesn’t retake the entire country, and to provide security for reconstruction.

Second, the Trump administration must increase its assistance to Sunni communities lucky enough to live outside Assad’s rule and help U.S.-supported local groups hold valuable territory in Syria’s southeast. This territory can provide local communities economic benefits now and political leverage down the line.

Third, the United States should work with regional allies to stop Iran from moving weapons and troops into Syria. That would require interdicting shipments by sea and ensuring that U.S.-supported forces control key border towns in Syria and Iraq. Such moves could check Iranian aggression without triggering armed conflict with Tehran.

“We need to cut off Iran’s ability to build a crescent of influence,” said the task force co-chair, retired Air Force General Charles Wald. “We need to continue to build our coalition with countries of like mind.”

Trump is right when he points out that he was dealt a terrible hand in Syria. The Obama administration policy of halfhearted support for the Syrian rebels and wishful diplomacy backed by no leverage led to the situation on the ground today. But Trump must not repeat Barack Obama’s mistakes.

“We have all sorts of cards to play here if we have the wit and wisdom to play them,” said former ambassador to Turkey Eric Edelman, the other co-chair.

There is no appetite in the United States for a prolonged military mission in Syria, but the lessons of the U.S. withdrawal from Iraq in 2011 are fresh in the minds of military leaders. Defense Secretary Jim Mattis pledged last week that U.S. forces would remain to prevent the emergence of “ISIS 2.0” and until the political process gets off the ground, but he stopped short of saying America would keep Iran’s aggression at bay.

The U.S. national security interest is clear. Long-term Iranian control in Syrian areas liberated from the regime and the Islamic State would cause further instability, fuel extremism and prolong the crisis.

“The United States Coalition with its partner forces on the ground have been the key to defeating ISIS, but liberating Syrians from ISIS into the hands of Iran will only perpetuate radicalization in the country,” said Mouaz Moustafa, executive director of the Syrian Emergency Task Force.

We are constantly told there is no military solution to the Syrian crisis, which is true. What’s also true is that no diplomatic solution is possible while Iran and Assad are still pursuing military victory and getting away with it.