The Malian Solidarity Bank is an ordinary-looking building that marks the centre of Timbuktu.

The concrete exterior is a little at odds with the signature dry-mud walls of the ancient city, and the cashpoint cubicle looks strangely modern with its reflective doors. They sit behind padlocked metal gates and the ATM has been out of service for nearly a year while it served as a women's prison.

Salaka Djikke, like scores of other women, was locked in this cramped space for violating the fundamentalist form of sharia imposed on Timbuktu while the city was ruled by affiliates of al-Qa'ida. The 25 year old's crime was to accept an evening ride on the back of her boyfriend's motorcycle.

As they arrived at his house at around 10 o'clock at night, four members of the jihadi religious police rushed at them. In a panic, the boyfriend drove off on the bike leaving her to face them. The four men began shouting at her in Arabic, a language few in the city speak, while one of them slapped her and another lashed her with a whip. "I couldn't understand what they were shouting and why they were whipping me," she said.

Ms Djikke was taken to the bank which had been commandeered as the Islamic police headquarters and locked in the ATM cell. Unable to lie down she tried to sleep sitting against the wall opposite the auto-teller.

Female prisoners languishing in the ATM became a commonplace during the Islamic occupation. Women and girls accused of violations from wearing inappropriate clothes to being with men they were not married to were kept there for days at a time while the new ruler next door decided their punishment.

Under the authority of the new police chief, Mohamed Mossa, this normally meant a public flogging. A West African preacher, or marabou, born in a village outside Timbuktu, Mr Mossa travelled in recent years to Saudi Arabia where he got funds to build a mosque, making himself the imam. When the Islamists of al-Qa'ida in the Islamic Maghreb (Aqim) and Ansar Dine took over the city last year the preacher was appointed chief of police.

Under his charge the bank branch had the word "police" sprayed on the wall, while the banking hall was converted into offices and a rudimentary court. Men with assault rifles would lounge outside under a black metal sign cemented into the wall with the symbol of the Koran and an AK-47 crossed by a cutlass.

"He was an agent of oppression," Drawi Maiga, Timbuktu's vice-mayor who stayed in the city throughout its occupation, said of the police chief. "He persecuted women. You can ask any woman in Timbuktu; they hated him."

The guns, black banners and fundamentalism that the jihadists brought to a city famed for its tolerance shocked many of its residents. Although overwhelmingly Muslim, the majority here belong to the Malakite sect whose preachers talk explicitly of the acceptance of all monotheistic religions. The Saudi-inspired Wahhabist doctrine of the militants was entirely alien.

One of the city's respected religious scholars, who spoke on condition of anonymity, said that "Islam is not about toughness; it's about kindness".

Efforts to temper the radicals included a request made to the home-grown Islamic group, Ansar Dine, to play a sermon by an Egyptian preacher and former jihadist who now calls for tolerance and non-violence. The request was refused. The same traditional religious leaders also begged for leniency from the Islamic police but their appeals were ignored.

Playing judge and jury, Mr Mossa sentenced Ms Djikke's to 95 lashes to be administered in a public market. She felt helpless, she said. "They (the Islamists) could execute people or amputate limbs and no one could do anything."

Sitting in the courtyard of her home in the backstreets of Mali's most famous city, with her head covered by a white shawl embroidered with coloured flowers she spoke in a whisper of the pain and humiliation of her flogging: "I was really hurt. This will stay with me all of my life. I try to stay strong but I will never forget."

She now believes that someone betrayed her to the Islamic authorities and admits that a small minority of her community has shunned her since. Before she was locked up in the ATM the jihadists had lectured her that it was a sin to be together with a man out of wedlock.

Despite the lashes she still disagrees. "Even if there is sharia law it is not a crime to be in love with a person."