TUNIS, Tunisia -- In Tunis, Ghaith stands furtively on a street corner, his face masked by a hoodie, his tense eyes scanning the crowd for any hint of Islamic State militants.
He chain-smokes as he describes the indiscriminate killing, the abuse of female recruits, the discomfort of a life where meals were little more than bread and cheese or oil. He recounts the knife held to his throat by fellow fighters who demanded he recite a particular Quranic verse on Islamic warfare to prove himself.
"It was totally different from what they said jihad would be like," said Ghaith, who asked to be identified by his first name only for fear of being killed. Ghaith eventually surrendered to Syrian soldiers.
While foreigners from across the world have joined the Islamic State militant group, some find day-to-day life in Iraq or Syria much more austere and violent than they had expected. These disillusioned new recruits also soon discover that it is a lot harder to leave than to join. The Syrian Observatory for Human Rights says the Islamic State group has killed 120 of its own members in the past six months, most of them foreign fighters hoping to return home.
Even if they manage to get out, former fighters are considered terrorists and security risks in their own countries. Thousands are under surveillance or in jail in North Africa and Europe, where former militants massacred 17 people last month in terror attacks in Paris.
"Not everyone who returns is a budding criminal. Not everyone is going to kill -- far from it," said France's top anti-terror judge, Marc Trevidic. "But it's probable that there is a small fringe that is capable of just about anything."
The number of French returnees has recently increased, their enthusiasm dented by the reality of militant life and by the allied bombing campaign, according to a top French security official who spoke anonymously because the issue is sensitive. Some foreign recruits have written home to say they are being held against their will, the official said.
The Associated Press talked to more than a dozen former fighters, their families and lawyers about life in and escape from Islamic State, many of whom spoke only on condition of anonymity for fear of retribution.
Youssef Akkari used to spend hours in his room in Tunisia listening to religious chants and reading, according to his brother, Mehdi Akkari. One day the family received a message that he was going to Syria. But he lost his glasses and couldn't fight, his brother said, so he was put in charge of preaching jihad to new recruits instead.
After seven months he began to plot his escape, along with two brothers.
The brothers were discovered and killed. Youssef turned himself in to Kurdish fighters and made his way back to Tunisia, where he felt trapped between police harassment and his terror of the vengeful militants. He returned to Syria and died in an airstrike in October.
The Islamic State group works to prevent recruits from leaving from the time they join.
The first step is removing their passports and identity documents. Hamad Abdul-Rahman, an 18-year-old Saudi, said he was met at the Syrian border last summer by militants who escorted him to a training camp in Tabaqa, Syria.
"They took all my documents and asked me if I want to be a fighter or a suicide bomber," Abdul-Rahman told AP from prison in Baghdad, where he was shackled, handcuffed and hooded.
He chose to fight.
In early September, he surrendered to Iraqi forces. An Iraqi defence ministry video shows Abdul-Rahman minutes after his arrest, identifying himself to soldiers.
Another Tunisian recruit, Ali, escaped after he was made a courier in the winter of 2013. He made four courier trips between Syria and Tunisia in three weeks, taking back news, money and propaganda videos. On the last trip to Tunisia, he simply stayed.
"I feel like I was a terrorist, I was shocked by what I did," said Ali, dropping his voice low and moving when people approached. His advice for would-be jihadis: "Go have a drink. Don't pray. It's not Islam. Don't give your life up for nothing."
The predicament for governments is to figure out whether a recruit is returning home to escape from the Islamic State or to spread its violence.
France has detained more than 150 returnees -- including eight on Tuesday -- and says about 3,000 need surveillance. Britain has arrested 165 returnees, and Germany considers about 30 of its 180 returnees extremely dangerous. There is no way to prove their intentions.
"(For many in France), they need to be punished. That's it," said Justice Minister Christian Taubira. "These are the people who can bear witness, who can dissuade others."
French lawyer Martin Pradel said his client is one of 10 men from Strasbourg who left for Syria last winter to take up arms on behalf of Syrian civilians. But they crossed into territory controlled by militants, who suspected they were spies or enemies. They were jailed for two weeks, then transferred and locked up for another three. Two of the French recruits died in an ambush.
The men decided to leave, one by one so as not to draw attention.
"They left at night, they ran across fields, they practically crept across the border," Pradel said.
His client surrendered to Turkish authorities. Since he lacked ID, he got temporary transit papers from the French embassy. He is now in jail in France, where the government accuses the Strasbourg men of running a recruiting ring for extremists.
It was a similar escape for four Frenchmen from Toulouse, according to their lawyers.
Pierre Dunac, the lawyer for Imad Jjebali, said the men went to Syria in hopes of helping civilians, but ended up in Islamic State territory and were thrown in jail. One day, Dunac said, their jailer gave them their papers. He told them, "I'm going to pray," and he left them alone right by the door.
"They understood that he was letting them leave," Dunac said. "Why? It's astonishing. ... They themselves didn't understand why."
The men surrendered to Turkish soldiers and were deported to France. They are now in jail facing terrorism charges.
In Tunisia, where close surveillance of 400 returnees is far more common than arrests, Ghaith is now a free man by most measures. But he does not act like one. He neck still bears a scar where his fellow fighters held the knife.
"It's not a revolution or jihad," he said. "It's a slaughter."
Hinnant reported from Paris. Associated Press writers Zeina Karam in Beirut; Jamey Keaten and Nicolas Vaux-Montagny in Paris; Vivian Salama in Baghdad; and Danica Kirka in London contributed.