Thomas Aquinas,
Summa Theologiae — Question 28 - OF THE SOLEMN RITE OF PENANCE…
“ The priest does not divulge the confession by imposing such a penance, though people may suspect the penitent of having committed some great sin. For a man is not certainly taken to be guilty, because he is punished, since sometimes one does penance for another: thus we read in the Lives of the Fathers of a certain man who, in order to incite his companion to do penance, did penance together with him. And if the sin be public, the penitent, by fulfilling his penance, shows that he has been to confession. ”
