The Hungarian parliament has passed a new legislation that criminalizes lawyers and activists who help asylum seekers in the country.

The legislation by Viktor Orbah’s government dubbed ‘Stop Soros Law’, named after the billionaire philanthropist it accuses of supporting Muslim migrants says any individual facilitating illegal immigration would face a year in jail.

The vote in Budapest came hours after a number of European Union leaders agreed to hold crisis talks on how to overhaul asylum rules.

Hungary alleges that immigration threatens its national security but its hardline stance and new law have faced widespread international criticism.

The United Nations refugee agency had urged Hungarian officials to scrap the proposed law while legal experts from the Council of Europe human rights organization appealed for the vote to be postponed until they had submitted a review of the measures on Friday.

Under the new law, anyone could be jailed for working for or with non-government organizations that are involved in helping or campaigning for asylum seekers