Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

France is planning to jail protesters who wear masks in the wake of weeks of violent demonstrations by the "yellow vest" movement.

Prime Minister Edouard Philippe said proposed legislation would target people who try to hide their identities while taking to the streets.

“We have to preserve the freedom to protest in France and punish those who want to violate this right,” Philippe said in an interview with broadcaster TF1 on Monday night.

French Prime Minister Edouard Philippe. Eric Feferberg / Reuters

His announcement follows weeks of anti-government protests which were sparked by a planned hike in gas taxes and have since morphed into a rebuke of President Emmanuel Macron’s policies.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

Masks have been confiscated by police officers at some "yellow vest" protests. The legislation would allow perpetrators to be sent to jail. At the moment, the offense is considered more minor and is punished with a fine.

Philippe said the proposed law would result in troublemakers being forced to pay property damage occurring during demonstrations, instead of taxpayers.

However, he offered few details about the specifics his plan.

In France, demonstrations have to be declared and authorized by municipal authorities at least three days before the planned date. Failing to comply with this can result in an organizer serving up to six months in prison and paying a $8,574 fine. The new penalties that would be proposed under Philippe's proposed legislation were not immediately clear.

Authorities have been able to fine demonstrators who wear masks "in circumstances which appear to infringe public order" since 2009, according to French media reports.

That has not stopped some protesters from wearing masks.

The “yellow vests” are named after their fluorescent yellow garb. They are expected to hold protests for the ninth consecutive week on Saturday.

What started as a largely peaceful movement has in recent weeks been prone to outbreaks of violence, with some protesters burning cars, looting stores and clashing with police.

Philippe said 80,000 members of the security forces and 5,000 police officers would be deployed across France this weekend to maintain public order.

Part of the government's challenge in appeasing and clamping down on the "yellow vests" is that the group is somewhat amorphous and does not have clear leaders or objectives.

The protesters appear to united by a general discontent over for the high cost of living in France and Macron's reformist agenda.