Airbnb is taking New York City to court. The company filed suit today over a new law, passed in July, that would make it easier for the city to crack down on illegal listings by requiring Airbnb and other home-sharing companies to share hosts’ names and addresses with the city’s enforcement agency on a monthly basis. In its suit, Airbnb says the law violates its users’ privacy and constitutional rights.

New York City council members passed the legislation last month in response to the perceived impact companies like Airbnb have on housing costs and availability. For Airbnb, its ability to do business as usual in New York City — its largest U.S. market — is at stake with this law, because by the city’s estimates, most of its listings are technically illegal.

“[T]he Ordinance is an unlawful end-run around established restraints on governmental action and violates core constitutional rights under the First and Fourth Amendments” Airbnb’s suit says, also calling the law “an extraordinary act of government overreach.”

The New York City enforcement agency responsible for investigating illegal rentals on Airbnb said that the law will help it more systematically go after cases of people skirting the law, which were previously discovered largely through anonymous tips.

“This law provides the City with the critical data it needs to preserve our housing stock, keep visitors safe, and ensure residents feel secure in their homes and neighborhoods, and the City will defend it,” Christian Klossner, executive director of the Mayor’s Office of Special Enforcement, said in a written statement.

The law could have a profound effect on Airbnb’s apartment-rental service: When similar legislation was passed in San Francisco, the number of listings on Airbnb fell by half. In New York, the Office of Special Enforcement estimates as many as two-thirds of listings on Airbnb are illegal.

After settling a lawsuit over the similar legislation in SF, Airbnb now works with the city to register hosts before they’re allowed to list on the platform, reducing the number of illegal listings.

The move for Airbnb to sue is the most recent development in the ongoing battle the company has faced in New York City for the past eight years.

Speaking at Code Conference this May, Airbnb CEO Brian Chesky said “In 2010, I said this is gonna be a one-year challenge. In 2011, I said this is probably gonna take a few years. In 2018, I said this is gonna take more than a few more years. It doesn’t seem like the end is in sight with that challenge.”