The Catholic Church has issued a warning to its clergy in Washington state: Any priest who complies with a new law requiring the reporting of child abuse confessions to authorities will be excommunicated.
https://www.newsweek.com/catholic-church-excommunicate-priests-following-new-us-state-law-2069039
If lawyers had to report the worst types of crimes committed by their clients, or ones they suspect them of having committed, don’t you think that would break down the legal system? So too with confession. For it to work, there has to be absolute secrecy. Punishments can apply anywhere else, investigations, reporting, whatever. But there fundamentally must be at least that one avenue for an individual to get legal help that is there for them and only them, or to have a priest hear their sins on behalf of God and offer absolution. Without secrecy, both structures would break down and a fundamental part of the legal system is the right of everyone to defend themselves, and a fundamental part of Catholicism is the availability of God’s forgiveness of sins.