I didn’t make it up. It was told to me by a former Catholic who related along these lines the experiences of a now-lapsed priest.
In Judaism there is no doctrine of clerical absolution and indulgences, but there is donating to charities to re-establish the connection with G-d that was damaged by the sin, albeit after a sincere repentance. Of course, this itself invites abuses similar to that which I described. Plenty of utterly repugnant people who have new wings of the synagogue named after them, or a Torah scroll commissioned.
By no means do I allege that this exclusively a Catholic phenomenon. Hypocrisy is as universal as ethics codes are. Can’t have one without the possibility of the other. And whatever your religious code, it’s meant for observance by humans, not angels, who always start out flawed, and often get worse instead of better over time.