Below is John Calvin on the confession of sins: to whom and in what manner we confess. As is always the case, there is much to mine in this short excerpt. But one major take away is Calvin's pastoral call for the redeemed to avail themselves of the blood of Christ shed for them for forgiveness of sins and cleansing of troubled consciences.
"As for the confession of sins, scripture teaches us thus: because it is the Lord who forgives, forgets, and wipes out sins, let us confess to Him to obtain grace and pardon. He is the Physician so let us show Him our wounds and sores. It is He who has been offended and wounded so let us ask of Him mercy and peace. It is He who knows the hearts and sees all the thoughts so let us open our hearts before Him. It is He who calls sinners so let us withdraw to Him.
"David says: "I have made known to you my sin and I have not hidden my iniquity. I said, `I will confess against myself, I will confess my unrighteousness to the Lord, and you have pardoned the iniquity of my heart"' (Ps. 32:5). Another confession of the same David is similar: "Have pity on me, Lord, according to your great mercy" (Ps. 51:1). Such is likewise the confession of Daniel: "We have sinned, Lord, we have done what is perverse, we have committed impiety and have rebelled against your commandments" (Dan. 9:5). There are enough other similar ones which are seen in scripture. "If we confess our sins;' says St. John, "the Lord is faithful to pardon us" (1 Jn. 1:9).
"To whom do we confess them? To Him certainly. That is, if with an afflicted and humbled heart we bow ourselves before Him; if in true sincerity, rebuking and condemning ourselves before His face, we ask to be absolved by His goodness and mercy. Whoever makes this confession of heart before God will also no doubt have a tongue ready to confess, when there is need to proclaim God's mercy among the people. And this not only to disclose the secret of his heart to a single person, once, in the ear, but freely to make known his poverty as well as God's glory, more than a few times, publicly and with all the world hearing. In this way, after having been rebuked by Nathan and being pierced with a goad of conscience, David confessed his sin before God and before people. He says: "I have sinned against the Lord" (2 Sam. 12:13), that is, "I do not want to excuse myself anymore, or equivocate so that everyone will not judge me to be a sinner, or so that what I wanted to hide from God might not be clear even to people." This is the way we must take the solemn confession which is made by the whole people at the admonition of Nehemiah and Ezra [Ezra 10:1-17; Neh. 9:1-37]. All churches ought to follow this example when they ask pardon from God, as is certainly the custom among churches which are well ordered." [emphasis added]John Calvin. The Institutes of Christain Religion, The First English Version of the 1541 French Edition