Pakistan's North West Frontier Province (NWFP) has passed a bill setting up a Taleban-style department under a cleric to enforce Islamic morality.
The NWFP is governed by an alliance of religious parties
It gives the new department the power to use the police and media for the promotion of Islamic values.
The NWFP is governed by an alliance of religious parties, the MMA, that is sympathetic to the Taleban.
It has already introduced measures such as the banning of music on public transport.
The BBC's Syed Shoaib Hassan in Karachi says the wording of the bill has been deliberately left vague and therefore open to different interpretations.
Critics say this leaves it open to misuse by politicians in the future.
Opposition MPs wore black armbands and staged a walkout from the assembly, saying their proposed changes to the law had been ignored.
The move comes only days before the federal assembly is due to debate moves to water down Islamic laws on divorce that have been denounced by women's groups.
The Hisba (Accountability) bill was passed in the NWFP assembly by a majority of 66 to 30.
Last year, the province's governor refused to sign a similar bill into effect, and the Supreme Court declared aspects of the proposed law unconstitutional.
Under the constitution, the provincial governor is obliged to agree to the latest version, as he is only allowed to veto a bill once.
President Musharraf denounced the original bill
He must give his assent within 30 days of the bill being presented to him.
Some of the provisions in the 2005 bill that the Supreme Court criticised have been dropped.
The department will not now have its own police force. It will, however, be able to requisition police "to promote virtue and prevent vice".
In other concessions, the power to cap spending on weddings or to enforce an Islamic dress code in public has been removed.
The legislation also allows the department to tackle issues like honour killings of women, child labour and ensuring the rights of minority religious groups.
"We had promised an Islamic system to the nation and approval of the Hisba bill is an important step in that direction," NWFP Chief Minister Akram Khan Durrani was quoted as saying by the Associated Press news agency.
Correspondents say that it remains to be seen which areas of its remit the department will choose to focus on.
Last year, President Pervez Musharraf denounced the original bill as a breach of fundamental human rights.