The way to stop it is to introduce a law that does exactly the opposite: that encrypted communication is always protected and should always be protected and that no legislation shall be introduced that weakens these technical guarantees.
That way, it essentially has to do a two step solution, of repealing the previous law that prohibits it, and then introducing their own.
That way, it essentially has to do a two step solution, of repealing the previous law that prohibits it, and then introducing their own.