The Greek behind your question is “τινων (of whomsoever) αφητε (you may remit) τας (the) αμαρτιας (sins) αφιενται (they are remitted) αυτοις (to them) αν τινων (whoesoever) κρατητε (you may retain) κεκρατηνται (they have been retained)”.
This verse is often understood as equivalent to that found in other places such as Matthew 16:19: “ο (whatever) εαν δησης (you may bind) επι (on) της (the) γης (earth) εσται (shall be) δεδεμενον (bound) εν (in) τοις (the) ουρανοις (heavens) και (and) ο (whatever) εαν λυσης (you may loose) επι (on) της (the) γης (earth) εσται (shall be) λελυμενον (loosed) εν (in) τοις (the) ουρανοις (heavens).”
So really you are asking does the state of being remitted/loosed (αφιενται/ λελυμενον) or retained/bound (κεκρατηνται/δεδεμενον) representing binding and loosing of individual sins, or of entire persons. Also, is the scope just on earth or forever. To answer this question we need to first understand that Jesus was a Jew speaking to Jewish people. Although the use of the words bind and loose (retain, or remit) in relation to the authority of Rabbis might be confusing to us, to the crowd that Jesus spoke the language could not be more natural.
According to Alfred Edersheim a Jewish historian:
no other terms were in more constant use in Rabbinic Canon-Law than those of ‘binding’ and ‘loosing.’ The words are the literal translation of the Hebrew equivalents Asar (אָסַר), which means ‘to bind,’ in the sense of prohibiting, and Hittir (הִתִּיר, from נָתַר) which means ‘to loose,’ in the sense of permitting (Edersheim, A. (1896). The Life and Times of Jesus the Messiah,Vol. 2, p. 85).
However there might be a slight distinction between retained and bound (κεκρατηνται and δεδεμενον) because in that although binding and loosing related only to ‘things’ (i.e. rules that are binding or not) retaining and remitting goes a little beyond that and seems to relate to a further function of the religious authorities actual judicial power.
By the first of these they ‘bound’ or ‘loosed’ acts or things; by the second they ‘remitted’ or ‘retained,’ declared a person free from, or liable to punishment, to compensation, or to sacrifice. These two powers—the legislative and judicial—which belonged to the Rabbinic office, Christ now transferred, and that not in their pretension, but in their reality, to His Apostles ((Edersheim, A. (1896). The Life and Times of Jesus the Messiah,Vol. 2, p. 85)
This distinction between bind/loose and retain/remit that Edersheim highlights does make sense as ‘retain’ in the Greek carries the idea of ‘having power over someone’ and to remit is ‘to send off or let go’. Thus retain/remit seems to extend beyond beyond the authority over actions to that over persons. Note the word forgiveness used here is by context related to the releasing or binding to the punishment of a law that is in itself declaring condemnation or forgiveness, alluding to the Rabbinical claimed powers at the time, rather then any claimed powers of the Christian church afterwards. In fact the Rabbis never once claimed the power ‘to forgive’ in the sense of gospel forgiveness. Although the same Greek word used here can be used to mean gospel forgiveness, in the context of binding and loosing this is in reference to remitting or retaining a person liable to a law. In fact nothing could be more offensive to the rabbinical culture at the time then to go around offering free forgiveness without any external obedience and deference to the 'binding' rules laid piled up by the Rabbis, especially to sinners and publicans, let alone Gentiles! This is why the Rabbis were very terribly angry with Christ when they accused him of blasphemy for declaring someone 'forgiven' and angrily said ‘only God can forgive sins’ which he countered by claiming to be God. (Mark 2:10–11)
I believe Catholics will argue from this that priests share Christ’s sacerdotal office actually administering forgiveness to Catholic church members (in some indirect way that does not rob Christ of his dignity) and Protestants will tend to interpret this authority as simply declaring the truth of the matter through an infallible gospel and also having power to excommunicate and settle doctrinal matters where people are consequentially involved. However, regardless of the theological application, the answer seems to be that Jesus was declaring that his Apostles had an authority of settling doctrinal and church matters with authority from heaven. There authority was infallibly provided for from heaven, which was therefore absolutely binding on earth. That the consequences of accepting or rejecting this newly founded gospel, that they dispensed to the community, rendered both a persons individual beliefs and actions right or wrong and consequentially there entire persons condemned or not, as the ultimate consequence. To answer the question then, the reference of the power that Christ gave to his church seems to cover 'both' individual laws and 'the who' (the persons themselves) that are liable to punishment or forgiveness under these new gospel rules. The scope can be looked at in minute detail as rules of excommunication and inclusion within the church under the Apostolic ministry or as wide as the keys of heaven opened up to the world by the church at large in publishing the gospel. In other words the authority is applicable in this life and in eternity to come for it is the very gospel itself that is holding the authority while church members are just conduits for its truth to reach the whole earth. There is nothing in the text itself that seems to limits this authority except the implicit understanding that only as it is consistent with Christ himself and his words does it retain the authority described.