Riyadh: A Saudi court sentenced 18 men, some of them foreigners, to jail terms of between seven months and 15 years on Monday after convicting them of fighting in foreign conflicts on behalf of Sunni Muslim extremist groups, state media reported.

The official SPA news agency did not specify which foreign conflicts they were found guilty of participating in but in recent months Saudi officials have expressed growing concern about Saudi volunteers fighting in the war in Syria, and Saudis have also been active in Iraq.

The 18 men were found guilty of “adopting a Takfiri ideology, and breaking away from the rule of the ruler by travelling to the lands of sedition to take part in fighting”, the news agency said. Takfiri is a term used to refer to those who brand Muslims who do not follow their own teachings as being apostates.

Some of the accused were also convicted of “forging identification papers and sheltering fugitives wanted by the security services”, it added.

Some were found guilty of possessing weapons and plotting to kill a Saudi policeman.

Other charges included “collecting funds to support fighters in Iraq” and posting recruitment videos on the internet.

The statement did not detail the nationalities of the foreigners among those convicted.

It said 13 of the 18 had lodged appeals.

Saudi officials have issued increasingly stern warnings against volunteers from the conservative Sunni Muslim kingdom heading off to fight alongside the mainly Sunni rebels trying to oust Syrian President Bashar Al Assad.

But diplomats say hundreds of Saudis, perhaps even several thousand, have gone regardless.

The involvement of Saudis in jihadist groups active in Iraq and Syria has stoked concerns in Riyadh of a resurgence of the deadly Al Qaida attacks that rocked the kingdom between 2003 and 2006.