It was enforced during licensing. In order to obtain a license from the FCC (which is effectively required to launch a satellite, unless you never want to communicate with it), you had to prove it would either deorbit naturally in < 25 years or that you had a system to do so at the end of the mission. The rule was generally to have a plan and an ability to deorbit after 25 years. A lot of satellites fail in ways that prevent using a propulsion system.