Mohamed Hashim Mohamed Zahran was 12 years old when he began his studies at the Jamiathul Falah Arabic College. He was a nobody, with no claim to scholarship other than ambition.
Zahran and his four brothers and sisters squeezed into a two-room house with their parents in a small seaside town in eastern Sri Lanka; their father was a poor man who sold packets of food on the street and had a reputation for being a petty thief.
"His father didn't do much," recalled the school's vice principal, S.M. Aliyar, laughing out loud.
The boy surprised the school with his sharp mind. For three years, Zahran practiced memorizing the Koran. Next came his studies in Islamic law. But the more he learned, the more Zahran argued that his teachers were too liberal in their reading of the holy book.
"He was against our teaching and the way we interpreted the Koran - he wanted his radical Islam," said Aliyar. "So we kicked him out."
Aliyar, now 73 with a long white beard, remembers the day Zahran left in 2005. "His father came and asked, 'Where can he go?'."
The school would hear again of Mohamed Zahran. And the world now knows his name. Sri Lankan officials have identified him as the suspected ringleader of a group that carried out a series of Easter Sunday suicide bombings in the country on April 21.
The blasts killed more than 250 people in churches and luxury hotels, one of the deadliest-ever such attacks in South Asia. There were nine suicide bombers who blew apart men, women and children as they sat to pray or ate breakfast.
Most of the attackers were well-educated and from wealthy families, with some having been abroad to study, according to Sri Lankan officials.
That description does not, however, fit their alleged leader, a man said to be in his early 30s, who authorities say died in the slaughter. Zahran was different.
Intelligence failings
Sri Lanka's national leadership has come under heavy criticism for failing to heed warnings from Indian intelligence services - at least three in April alone - that an attack was pending. But Zahran's path from provincial troublemaker to alleged jihadist mastermind was marked by years of missed or ignored signals that the man with a thick beard and paunch was dangerous.
His increasingly militant brand of Islam was allowed to grow inside a marginalized minority community - barely 10 percent of the country's roughly 20 million people are Muslim - against a backdrop of a dysfunctional developing nation.
The top official at the nation's defence ministry resigned on Thursday, saying that some institutions under his charge had failed.
For much of his adult life, Zahran courted controversy inside the Muslim community itself.
In the internet age, that problem did not stay local. Zahran released online videos calling for jihad and threatening bloodshed.
After the blasts, ISIS claimed credit and posted a video of Zahran, clutching an assault rifle, standing before the group's black flag and pledging allegiance to its leader.
The precise relationship between Zahran and ISIS is not yet known. An official with India's security services, who spoke on condition of anonymity, said that during a raid on a suspected Islamic State cell by the National Investigation Agency earlier this year officers found copies of Zahran's videos. The operation was in the state of Tamil Nadu, just across a thin strait of ocean from Sri Lanka.
"Like a spoiled child"
Back in 2005, Zahran was looking to make his way in the world. His hometown of Kattankudy is some seven hours' drive from Colombo on the other side of the island nation, past the countless palm trees, roadside Buddha statues, cashew hawkers and an occasional lumbering elephant in the bush. It is a town of about 40,000 people, a dot on the eastern coast with no clear future for an impoverished young man who'd just been expelled.
Zahran joined a mosque in 2006, the Dharul Athar, and gained a place on its management committee. But within three years they'd had a falling out.
"He wanted to speak more independently, without taking advice from elders," said the mosque's imam, or spiritual leader, M.T.M. Fawaz.
Also, the young man was more conservative, Fawaz said, objecting, for instance, to women wearing bangles or earrings.
"The rest of us come together as community leaders but Zahran wanted to speak for himself," said Fawaz, a man with broad shoulders lounging with a group of friends in a back office of the mosque after evening prayers. "He was a black sheep who broke free."
Mohamed Yusuf Mohamed Thaufeek, a friend who met Zahran at school and later became an adherent of his, said the problems revolved around Zahran's habit of misquoting Islamic scriptures.
The mosque's committee banned him from preaching for three months in 2009. Zahran stormed off.
"We treated him like a spoiled child, a very narrow-minded person who was always causing some trouble," said the head of the committee, Mohamed Ismail Mohamed Naushad, a timber supplier who shook his head at the memory.
Now on his own, Zahran began to collect a group of followers who met in what Fawaz described as "a hut".
At about that time, Zahran, then 23, married a young girl from a small town outside the capital of Colombo and brought his bride back to Kattankudy, according to his sister, Mathaniya.
"I didn't have much of a connection with her - she was 14," she said.
Despite being "a bit rough-edged", Zahran was a skilled speaker and others his age were drawn to his speeches and Koranic lessons, said Thaufeek. He travelled the countryside at times, giving his version of religious instruction as he went.
Also, Zahran had found a popular target: the town's Sufi population, who practice a form of Islam often described a mystical, but which to conservatives is heresy.
Tensions in the area went back some years. In 2004, there was a grenade attack on a Sufi mosque and in 2006 several homes of Sufis were set afire. Announcements boomed from surrounding mosques at the time calling for a Sufi spiritual leader to be killed, said Sahlan Khalil Rahman, secretary of a trust that oversees a group of Sufi mosques.
He blamed followers of the fundamentalist Wahhabi strain of Islam that some locals say became more popular after funding from Saudi Arabia, the birthplace of Wahhabism, flowed to mosques in Kattankudy.
It was, Rahman said, an effort "to convert Sufis into Wahhabis through this terrorism". Rahman handed over a photograph album showing charred homes, bullet holes sprayed across an office wall and a shrine's casket upended.
Online radical
It was an ideal backdrop for Zahran's bellicose delivery and apparent sense of religious destiny.
He began holding rallies, bellowing insults through loudspeakers that reverberated inside the Sufis' house of worship as they tried to pray.
In 2012, Zahran started a mosque of his own. The Sufis were alarmed and, Rahman said, passed on complaints to both local law enforcement and eventually national government offices. No action was taken.
The then-officer in charge of Kattankudy police, Ariyabandhu Wedagedara, said in a telephone interview that he couldn't arrest people simply because of theological differences.
"The problem at the time was between followers of different Islamic sects - Zahran was not a major troublemaker, but he and followers of other sects, including the Sufis, were at loggerheads," Wedagedara said.
Zahran found another megaphone: the internet. His Facebook page was taken down after the bombings, but Muslims in the area said his video clips had previously achieved notoriety.
His speeches went from denouncing Sufis to "kafirs", or non-believers, in general. Zahran's sister, Mathaniya, said in an interview that she thought "his ideas became more radical from listening to Islamic State views on the Internet".
In one undated video, Zahran, in a white tunic and standing in front of an image of flames, boomed in a loud voice: "You will not have time to pick up the remains of blown-up bodies. We'll keep sending those insulting Allah to hell."
"Hard to take"
Zahran spoke in Tamil, making his words available to young Muslims clicking on their cellphones in Kattankudy and other towns like it during a period when, in both 2014 and 2018, reports and images spread of Sinhalese Buddhists rioting against Muslims in Sri Lanka.
In 2017, Zahran's confrontations boiled over. At a rally near a Sufi community, his followers came wielding swords. At least one man was hacked and hospitalized. The police arrested several people connected to Zahran, including his father and one of his brothers. Zahran slipped away from public view.
That December, the mosque Zahran founded released a public notice disowning him. Thaufeek, his friend from school, is now the head. He counted the places that Zahran had been driven away from - his school, the Dharul Athar mosque and then, "we ourselves kicked him out, which would have been hard for him to take".
The next year, a group of Buddha statues was vandalised in the town of Mawanella, about five hours drive from Kattankudy. There, in the lush mountains of Sri Lanka's interior, Zahran had taken up temporary residence.
"He was preaching to kill people," said A.G.M. Anees, who has served as an imam at a small mosque in the area for a decade. "This is not Islam, this is violence."
Zahran went into hiding once more.
On the Thursday morning before the Easter Sunday bombings, Zahran's sister-in-law knocked on the door of a neighbour who did seamstress work near Kattankudy. She handed over a parcel of fabric and asked for it to be sewn into a tunic by the end of the day.
"She said she was going on a family trip," said the neighbour, M.H. Sithi Nazlya.
Zahran's sister says that her parents turned off their cellphones on the Friday. On Sunday, when she visited their home, they were gone.
She does not know if Zahran arranged for them to be taken somewhere safe. Or why he would have carried out the bombing.
But now in Kattankudy, and in many other places, people are talking about Mohamed Hashim Mohamed Zahran.
Track Latest News Live on NDTV.com and get news updates from India and around the world