With already 4 responses worth consideration, bit reluctant to provide yet another view. And, as well, each ‘view’ of this situation will depend on your foundation, that is, there is a lot ‘behind’ any responses that simply for logistical reasons can’t be written as part of that response.
Nevertheless I feel there is more to consider. First context! In both Matthew’s and Marks account, the preceding incident needs to come into consideration. Peter had answered a question from Jesus, and Jesus responded ...
MAT 16:17 Jesus answered and said to him, “Blessed are you, Simon Bar-Jonah, for flesh and blood has not revealed this to you, but My Father who is in heaven
Note the source for the response! Whereas with the ‘get behind me Satan’ response, Jesus said ..
MARK 8:33 [snip] * Get behind Me, Satan! For* you are not mindful of the things of God, but the things of men.”
Who do you think the ‘you’ refers to? Satan? And if so, since when is Satan mindful of the ‘things of men’? I argue that ‘you’ is Peter.
It’s all about the ‘source’. What is the ‘source’ of what you ‘say’. Your own reasoning? Or? Unlike the previous incident, It’s clear Peter was ‘thinking’ based on his own thinking. The result of the ‘fall’ was man became self righteous. Man [intuitively] depended on ‘self’. Peter on other occasions reflected this. And why not — ‘man’ could not yet be ‘reborn’, so at this time, Peter still had a ‘separated’ spirit. So he could only rely on his own reasoning - why? - because of the ‘fall’, and who was responsible for that? Satan.
So Peters response was such that it was not inspired by the Holy Ghost (as previously) - but a result of what Satan had done (4000 yrs earlier.) Hence the words of Jesus.
So to answer the query, who was Jesus addressing? He was ‘addressing the ‘source’ of the reasoning that lead to the outburst.
But the issue with this ‘section’ of the gospels is that it has fuelled much speculation. And [some really ridiculous] questions - [such as] - how could Peter be possessed, or, used by Satan. The questions may be valid, but they too easily lead towards erroneous conclusions. So my response above may well provoke reaction! Nevertheless it needed to be presented as an alternative.