For the most part, Putin responded by sending Russian security services into jihadist hot spots like Dagestan. Rhetorically, Putin and the Russian propaganda machine capitalize on these attacks by portraying all Kremlin enemies, both foreign and domestic, as part of a vast terrorist conspiracy. The Russian state seeks to craft an image of protector of the people.

Now, Moscow’s entanglements in the Middle East have aligned it against Sunnis and their interests. In the months ahead, as Russia’s involvement with the Syrian civil war deepens, it’s a near-certainty that Sunni militants will intensify their burgeoning campaign against Russia.

Since Russia entered the war in Syria in 2015, it has been increasingly perceived as a vanguard of Shia interests. Russian President Vladimir Putin has provided substantial military aid to Syrian leader Bashar al-Assad, allying Russia with the Shia Iran and Lebanese Hezbollah, avowed enemies of Sunni jihadists. An ISIS propaganda video threatening retaliation against Russia was released just two weeks after the downing of Metrojet Flight 9268 over the Sinai in 2015. That attack was intended as a terrifying message to Putin that his actions in Syria, where the Russian air force was bombing Sunni rebel positions, would not go unreciprocated.

For Russia, the demographics are also daunting. There are thousands of Russian citizens fighting with ISIS, and another 5,000 to 7,000 Russian-speaking jihadists, making Russian the second-most popular language spoken within ISIS. This means that Sunni jihadist groups have a ready-made, native force to send back home to Russia, where the militants can more easily blend in with local populations while plotting further attacks.

Perhaps the key reason why Sunni attacks on Russia proper will increase, however, is the fallout between Sunni jihadists in the Caucasus—namely, the al-Qaeda-linked Caucasus Emirate and the Wilayat Qawqaz, ISIS’s official representative on Russia’s periphery. In recent years, many high-ranking jihadists have switched allegiance from the Caucasus Emirate to Wilayat Qawqaz. ISIS, in their eyes, is the most legitimate force espousing the austere brand of Salafism popular among jihadists, particularly the younger generation. The split between the two groups will continue to manifest, likely resulting in a process of outbidding where violent non-state groups rely on spectacular attacks to persuade potential acolytes that their terrorist or insurgent organization has a stronger resolve to fight the adversary—in this case, the Russian state and security services. The competition has even extended to the battlefield in Syria, which has only heightened the stakes.

Much of the violence afflicting Russia may, in the end, stem from its own actions. Prior to the 2014 Winter Olympics in Sochi, Russian authorities, including the Federal Security Service of the Russian Federation, allegedly encouraged Sunni militants to leave Russia for Syria, where they could wage jihad against the Assad regime. But with the caliphate now under strain, some of these relocated militants might attempt to return home and link up with jihadists in Dagestan, Chechnya, or other restive Russian republics. Putin has expressed concern about this possibility, lamenting that after Syria, these militants will not simply “vanish into thin air.” Moreover, Russia’s approach to counterinsurgency eschews addressing grievances, instead relying almost exclusively on military force. This means that while militants can be killed and captured, the root causes of the political violence go largely ignored, allowing the ideology fueling militant Salafists to fester indefinitely.