Californians who post naked photos of their ex-lovers online to get revenge can now get six months in jail and a $1,000 fine.

California Governor Jerry Brown recently signed Senate Bill 255 banning "revenge porn," which is when people post nude pictures of someone else online without their permission with an intention to shame that person, reports the Associated Press.

"Until now, there was no tool for law enforcement to protect victims. Too many have had their lives upended because of an action of another that they trusted," said the bill's sponsor State Senator Anthony Cannella (R).

According to Cannella, revenge porn is a growing problem in California with many jilted folks turning to the web to get back at a former flame.

While the bill had bipartisan support, the American Civil Liberties Union opposed the measure because it might infringe on free speech rights.

The weakness of the bill may be in the motive of the perpetrator, says UCLA law professor Eugene Volokh.

"It does require intent to cause serious emotional distress. In certain situations, the reason people distribute this material is for money." Volokh told CNN.

Sources: CNN and Associated Press