A prosecutor in the Iranian capital Tehran has said that an unnamed woman who removed her obligatory Islamic headscarf in public has been sentenced to 24 months in prison, three months without parole.

Iran's semi-official Tasnim news agency on Wednesday quoted prosecutor Abbas Jafari Dolatabadi as saying the woman took off her headscarf in Tehran's Enghelab Street to 'encourage corruption through the removal of the hijab in public'.

Dolatabadi, who announced the sentence, said the woman intended to appeal against the verdict, the judiciary's Mizan Online news agency reported.

Scroll down for video

All women in Iran must be fully veiled in public at all times, according to a law in place since the Islamic Revolution of 1979 (file photo)

A recent protest against compulsory veil wearing in Iran turned nasty when a police officer climbed onto a podium and pushed a demonstrator onto the pavement, earning jeers from spectators

A university student attends a December 2017 protest inside Tehran University while a smoke grenade is thrown by Iranian police

The woman 'encouraged moral corruption' in public, he said, criticising the light nature of the sentence and saying he would push for the full two-year penalty.

More than 30 Iranian women have been arrested since the end of December for publicly removing their veils in defiance of the law.

Most have been released, but many are being prosecuted.

Iranian law in place since the Islamic Revolution of 1979 stipulates that all women, Iranian or foreign, Muslim or non-Muslim, must be fully veiled in public at all times.

But the zeal of the country's morality police has declined somewhat in the past two decades, and a growing number of Iranian women in Tehran and other large cities often wear loose veils that reveal their hair.

In some areas of the capital, women are regularly seen driving cars with veils draped over their shoulders.

Dolatabadi said he would no longer accept such behaviour, and had ordered the impound of vehicles driven by socially rebellious women.

The prosecutor said some 'tolerance' was possible when it came to women who wear the veil loosely, 'but we must act with force against people who deliberately question the rules on the Islamic veil', according to Mizan Online.

The police say the campaign against the veil is backed by Farsi-language satellite TV networks based abroad and purportedly encouraged women participants to take their white headscarves off on Wednesdays.

Women showing their hair in public in Iran are usually sentenced to far shorter terms of two months or less, and fined $25.

Last month police warned that Iranian women protesting against the compulsory headscarf by taking off their hijab in public could be facing up to a decade in jail for 'inciting prostitution'.

The authorities are eager to stem growing protests across the country against the dress code enforced on women.

The recent wave of defiance started with Vida Movahed, a 31-year-old mother-of-one whose protest and subsequent arrest on December 27 became headline news all over the world.

A video showing her calmly waving her white hijab tied to a stick above the crowds in the Iranian capital, went viral on social media.

Ms Movahed, who became known as The Girl In Enghelab Street, was released over the weekend, after spending a month in custody with her 20-month-daughter.

President Hassan Rouhani came to power in 2013 promising a more moderate stance - he has previously said it is not the job of police to enforce religious rules such as those forcing women to cover their hair

Thousands of social media users shared messages of support after her disappearance, dubbing her the 'Girl of Enghelab Street' after the area in central Tehran where she staged the protest.

Iranian activists started a Twitter campaign using the hashtag #WhereIsShe, demanding that the government reveal what happened to her.

The campaign eventually went global both on and offline, with protesters at the recent Women's March in the U.S. waving placards with the slogan.

President Hassan Rouhani, who came to power in 2013 promising a more moderate stance, has previously said it is not the job of police to enforce religious rules such as those forcing women to cover their hair.

But in April 2016, officials said there were 7,000 undercover morality police reporting on things like 'bad hijab' - a blanket term usually referring to un-Islamic dress by women.

