Iowa Gov. Kim Reynolds signed a bill into law Thursday that critics are calling “Ag Gag 2.0” just two months after a federal judge struck down a similar law as unconstitutional.

The law creates a specific trespass crime for a person who lies to get into an agricultural facility with the intent to cause financial or physical damage. It would allow the prosecution of people who go undercover to investigate livestock operations, slaughterhouses and puppy mills.

“Untrained, unapproved and unwanted items or people entering farms put farmers and the economy of the state at risk,” Reynolds said. “Laws like this help further the security and safety of our farmers, our state, or our nation and our world, and I’m proud to sign it today.”

The law goes into effect immediately.

The 2012 law made it a crime for people to obtain access to an agricultural facility using false pretenses. The U.S. District Court for the Southern District of Iowa ruled the law is unconstitutional because it violates the First Amendment’s free speech protections.

The state is appealing that ruling.

ACLU of Iowa Executive Director Mark Stringer said the new law is also unconstitutional because news coverage of “bad practices” inside livestock and other ag facilities “inevitably damages a business’s reputation, which is just one way that this law tramples on protected speech.”

Stringer said this tries to give special protection to the agriculture industry.

“It would have a chilling effect on exposing problematic worker conditions, health and safety violations, and animal cruelty,” Stringer said.

The House and Senate passed the new bill Tuesday, with some Democrats joining Republicans to vote in favor.

House Speaker Linda Upmeyer, R-Clear Lake, said she is very concerned about biosecurity.

Asked if the legal bills piling up from the first law and likely court challenge of the new law are worth it, she pointed to the losses Iowa suffered because of the 2015 bird flu outbreak.

“Whether it’s intentional or unintentional, I think the security involved in these kinds of facilities is necessary,” Upmeyer said.