When I was 14, my family and I made our way to my father's military club in Khartoum where we had been dining for years. On this occasion, we were denied entry as I was not wearing a headscarf. Upon my father's protestations that this had never happened before he was informed by staff that it was the government's new directive; all women had to wear the hijab in public and no trousers or revealing clothes were permitted.

We went back to the car, fashioned an awkward headscarf for me to wear and made our way to dinner as my teenage embarrassment obliterated my appetite. This was life in the new Khartoum after the National Salvation coup in 1989. Music with "irreligious" lyrics was banned from the airwaves, open-air parties using sound systems were prohibited after 11pm (spawning what came to be known as the "overnight", where the performer was smuggled indoors to entertain the cognoscenti until the wee hours of the morning) and a strict curfew was imposed. Officious gatekeepers were positioned outside college campuses to veto female attire, and many's the time they sent a frustrated student in search of a safety pin to reunite the hems of an offending slit skirt.

Last week, several women were rounded up at a cafe in Khartoum and flogged for sporting indecent wear, namely trousers, while the remainder await trial as they had refused to plea bargain and accept a punishment of "only" 10 lashes for their sins.

Until recently, sporadic raids on private parties in Sudan were not uncommon, particularly on New Year's Eve. If there was alcohol on the premises there would be hell to pay. The manner of punishment was often deliberately humiliating: head shaving, flogging or alerting the families of those appearing to be particularly cocky or affluent to inflict maximum ignominy.

Over the past few years however, there has been a discernible relaxation of those draconian public decency laws. In a city allegedly under sharia law, an increasingly affluent populace, an influx of expatriates and an expansion of the United Nations mission have created a sort of bubble of restaurants, banqueting halls and other venues where women mingle with men, smoke shisha and roam hijab-free and trouser-clad.

The group of arrested women, unfortunately for the Sudanese authorities, included Lubna al-Hussein, a rather feisty female journalist and employee of the UN who appears to be spearheading a campaign to garner maximum publicity for her coming trial. The group also reportedly included non-Muslim women from the south of the country (a minority in the north and one that was assured, as part of the north-south peace agreement, that sharia would not apply to its members). The incident has prompted a member of the southern SPLM – now incorporated into the ranks of the government – to demand an investigation into the event, hinting at concerns over the viability of a united Sudan as the 2011 referendum (when the south will vote for or against secession) looms.

The difficulties of governing two different communities in one country under two different sets of laws are highlighted by the harsh punishment for brewing of illegal alcohol known as "araqi", more often than not concocted by poor women from the south. On a recent trip back to Khartoum, I watched from my window as a family of southern squatters stood by while their makeshift tents were burned to the ground by public order police as punishment for brewing alcohol illegally.

There has been a media blackout on the latest floggings in Khartoum and the word on the street is that the security officer who engineered the cafe raid was a lone ranger provoked by al-Hussein's tone when he urged the women to act or dress more modestly. Her lawyer stated that such raids were to remind people "that Big Brother is watching you", and there is certainly an element of this in the government's rather erratic approach to its implementation of sharia.

Since this commitment to divine law is cosmetic and not in earnest, the religious whip is cracked when there may be a perception that the regime is going soft, using Islam as proxy for authoritarianism. However, the whole affair is embarrassing for the government, which finds itself in a Catch-22. To go ahead with the trial of the remaining women would be a step backwards, bad for its new foreign investment-attracting, oil-exporting image (France has already expressed its chagrin), but President Omar al-Bashir et al are not yet secure enough in their positions to accept the ongoing dilution of religious decorum, dismantle public order laws and withdraw their mandate from such outfits as the public order police. I predict a face-saving magnanimous presidential "pardon", such as the one bestowed upon Gillian Gibbons – one that does not discredit the initial charge but halts proceedings or stays punishment.

What these women were wearing is hardly the point. They were just an easy target for someone's discomfort with the challenge they posed to convention, traditionalism and the status quo. As with all self-declared Islamic governments, what a woman wears becomes no longer an issue of religious modesty but one of audacity and defiance to a regime's raison d'etre and authority.