Turkey warned the Syrian government Monday against entering the Kurdish-controlled enclave in northern Syria where a major Turkish military offensive is underway, saying it would hit back at Syrian troops if their goal is to protect the Kurdish fighters.

The warning sets up a potential clash between Turkish troops and Syrian forces backed by Iran and Russia, whose deployment would be a first step toward restoring President Bashar al-Assad’s presence along the Turkish border.

The warning by the Turkish foreign minister came shortly after Syrian state media said pro-government forces would enter Afrin within hours to bolster local forces in confronting Turkey’s “aggression” after reaching an agreement with the Kurdish militia, which controls Afrin.

Details of the deal with the Kurdish People’s Protection Units, or YPG, were not announced by either side. Kurdish officials said talks were underway. By nightfall, no troops had entered Afrin.

Assad’s troops have had no presence in Afrin since they pulled out of most of northern Syria in 2012, as nationwide protests against Assad sparked a civil war. A return to the area, where a potent mix of regional and international powers have boots on the ground, could further complicate the situation and lead to unwanted confrontations.

But depending on the details of the agreement, it may also serve to defuse the situation in Afrin, where Turkey has been struggling to achieve results in its month-long offensive to push back YPG fighters from its borders.

Ankara considers the YPG a “terrorist group” linked to the Kurdish insurgency within Turkey’s borders. It launched a major offensive last month, pounding the enclave with airstrikes and artillery on a daily basis.

Speaking at a news conference in Amman, Jordan, Turkish Foreign Minister Mevlut Cavusoglu said Turkey would have no problem if Syrian government forces were entering Afrin to clear the area of YPG fighters. But, he said, it would strike back if it learns the deployment was meant to shore up the Kurds against Turkey.

“If the regime is entering to protect the YPG, then no one can stop us, stop Turkey or the Turkish soldiers,” he said.

Turkish Deputy Prime Minister Bekir Bozdag later denied the Syrian state media reports, saying they had “not been confirmed by authorities.” He added, however, that any move to protect the Kurdish fighters would be a “disaster” for the region.

Turkey has supported rebels fighting to overthrow Assad throughout the seven-year civil war, but in recent years, it has focused more on trying to contain the Kurds. Government troops deployed along its borders, at this point, may be more palatable for Ankara than the continued presence of the powerful YPG.

— Associated Press