Malaysia has strengthened its controversial sedition law, imposing a minimum jail term of three years and allowing the government to block online media deemed to be seditious, lawmakers said Friday.

The toughening of the Sedition Act, which dates back to British colonial rule, comes after a crackdown in which scores of people have been detained under the law in recent weeks since opposition leader Anwar Ibrahim was jailed in February on sodomy charges.

The latest amendments to the law passed through parliament after more than 12 hours of debate that dragged into the early hours of Friday. The changes drew criticism at home and abroad, including from the United Nations.