Apple was supposed to help the Indian government make an anti-spam iPhone app that would let users mark and report spam callers, but instead faces potential legal trouble down the road because the Telecom Regulatory Authority of India (TRAI) has warned that iPhone could be “derecognized” from local wireless networks if the company rejects its software.

As a result, iPhone owners in India would be unable to connect to any supported cellular network. The government watchdog’s thinly veiled threat was specified in a letter sent to Indian carriers over the summer, saying it would give carriers six months notice to derecognize all non-complying devices from their networks.

Naturally Apple asked for the clause about derecognition to be dropped. The Indian Cellular Association has also come out in opposition to the regulator’s move.

“We look forward to working with TRAI to address the issue of unsolicited commercial communications, while simultaneously ensuring that we fully honor our commitment to protect the privacy and security of our users,” Apple’s head of Public Policy in India, Kulin Sanghvi, wrote in a letter, dated June 18, which responded to a draft of the proposed notification.

TRAI Chairman R.S. Sharma said the notification could not be quashed or challenged by writing a letter. “The most appropriate way to challenge this is in court,” he said.

For those wondering, the app has been available on Android since 2016.

Reuters reported Thursday that Apple has refused to give its blessing to the app over privacy worries stemming from letting the software access customers’ calls and text logs.

Back in March, the Cupertino firm told the news gathering organization that TRAI’s app “as envisioned violates the privacy policy of App Store.” However, iOS 12 includes support for manual reporting of unwanted texts and calls as spam, which led some watchers to speculate that this new capability for developers might have come in response to the Apple-TRAI feud.

Apple is apparently planning to impose strict sales targets on retailers, give training to retail staff, provide year-round discounts in cooperation with banks and retailers, overhaul third-party store branding, push forward with plans to open its own stores in the country and more.