A rally outside the Ukrainian Parliament building has turned violent as activists set tires on fire. Meanwhile, MPs have adopted a law that bans the closest allies of Ukraine’s deposed President Yanukovich from politics.

Dozens of hooded people gathered outside the parliament in Kiev shouting "Lustration!"

Police were forced to cordon off the building as the protesters rallying for Yanukovich-era officials to be removed from their posts put tires on fire, set off several fireworks and pelted eggs at the law enforcers.

The thick smoke and heat made the police retreat somewhat. Live streams from the scene showed several people were detained and one person taken away by a medic team.

At least three people, two civilians and a National Guard soldier, have sustained “traumas of varying degrees of severity,” Kiev police said later in an official statement.

Рада провалила закон о люстрации, активисты перекрыли Грушевского http://t.co/q7XaF84hHLpic.twitter.com/DKUnDbXUOn — Новое Время (@tweetsNV) September 16, 2014

As the law was adopted, the crowd cheered and applauded.

The so-called lustration bill has been supported by 231 members of parliament - the minimum required is 226 votes - during the second and the last reading. If signed into law by President Petro Poroshenko, MPs who worked under Viktor Yanukovich will be forced to leave the parliament and will be permanently banned from occupying seats.

Верховна Рада проголосувала ЗА закон "Про очищення влади" - люстрації бути! pic.twitter.com/XHKhl75FH1 — Люстраційний комітет (@luscomitet) September 16, 2014

Ukraine has not previously employed lustration. The bill was earlier adopted in the first reading in mid-August. The bill’s authors propose checking candidates for government positions before appointment.

“Under the bill, those who failed the check are those who held office between February 25, 2010 and February 22, 2014. In particular, Ukraine's president, prime minister, first deputy prime minister, vice prime ministers of Ukraine, ministers, heads of the security service, the General Prosecutor's office, and national Bank,” the draft law reads.

The law, MPs said, would revive people’s trust in the government.