Aristotle, Rhetoric, Book II, Part 6 (translated by W. Rhys Roberts):
We now turn to Shame and Shamelessness; what follows will explain the things that cause these feelings, and the persons before whom, and the states of mind under which, they are felt. Shame may be defined as pain or disturbance in regard to bad things, whether present, past, or future, which seem likely to involve us in discredit; and shamelessness as contempt or indifference in regard to these same bad things. If this definition be granted, it follows that we feel shame at such bad things as we think are disgraceful to ourselves or to those we care for. These evils are, in the first place, those due to moral badness. Such are throwing away one's shield or taking to flight; for these bad things are due to cowardice. Also, withholding a deposit or otherwise wronging people about money; for these acts are due to injustice. Also, having carnal intercourse with forbidden persons, at wrong times, or in wrong places; for these things are due to licentiousness. Also, making profit in petty or disgraceful ways, or out of helpless persons, e.g. the poor, or the dead - whence the proverb 'He would pick a corpse's pocket'; for all this is due to low greed and meanness. Also, in money matters, giving less help than you might, or none at all, or accepting help from those worse off than yourself; so also borrowing when it will seem like begging; begging when it will seem like asking the return of a favour; asking such a return when it will seem like begging; praising a man in order that it may seem like begging; and going on begging in spite of failure: all such actions are tokens of meanness. Also, praising people to their face, and praising extravagantly a man's good points and glozing over his weaknesses, and showing extravagant sympathy with his grief when you are in his presence, and all that sort of thing; all this shows the disposition of a flatterer. Also, refusing to endure hardships that are endured by people who are older, more delicately brought up, of higher rank, or generally less capable of endurance than ourselves: for all this shows effeminacy. Also, accepting benefits, especially accepting them often, from another man, and then abusing him for conferring them: all this shows a mean, ignoble disposition. Also, talking incessantly about yourself, making loud professions, and appropriating the merits of others; for this is due to boastfulness. The same is true of the actions due to any of the other forms of badness of moral character, of the tokens of such badness, &c.: they are all disgraceful and shameless. Another sort of bad thing at which we feel shame is, lacking a share in the honourable things shared by every one else, or by all or nearly all who are like ourselves. By 'those like ourselves' I mean those of our own race or country or age or family, and generally those who are on our own level. Once we are on a level with others, it is a disgrace to be, say, less well educated than they are; and so with other advantages: all the more so, in each case, if it is seen to be our own fault: wherever we are ourselves to blame for our present, past, or future circumstances, it follows at once that this is to a greater extent due to our moral badness. We are moreover ashamed of having done to us, having had done, or being about to have done to us acts that involve us in dishonour and reproach; as when we surrender our persons, or lend ourselves to vile deeds, e.g. when we submit to outrage. And acts of yielding to the lust of others are shameful whether willing or unwilling (yielding to force being an instance of unwillingness), since unresisting submission to them is due to unmanliness or cowardice.
These things, and others like them, are what cause the feeling of shame. Now since shame is a mental picture of disgrace, in which we shrink from the disgrace itself and not from its consequences, and we only care what opinion is held of us because of the people who form that opinion, it follows that the people before whom we feel shame are those whose opinion of us matters to us. Such persons are: those who admire us, those whom we admire, those by whom we wish to be admired, those with whom we are competing, and those whose opinion of us we respect. We admire those, and wish those to admire us, who possess any good thing that is highly esteemed; or from whom we are very anxious to get something that they are able to give us - as a lover feels. We compete with our equals. We respect, as true, the views of sensible people, such as our elders and those who have been well educated. And we feel more shame about a thing if it is done openly, before all men's eyes. Hence the proverb, 'shame dwells in the eyes'. For this reason we feel most shame before those who will always be with us and those who notice what we do, since in both cases eyes are upon us. We also feel it before those not open to the same imputation as ourselves: for it is plain that their opinions about it are the opposite of ours. Also before those who are hard on any one whose conduct they think wrong; for what a man does himself, he is said not to resent when his neighbours do it: so that of course he does resent their doing what he does not do himself. And before those who are likely to tell everybody about you; not telling others is as good as not believing you wrong. People are likely to tell others about you if you have wronged them, since they are on the look out to harm you; or if they speak evil of everybody, for those who attack the innocent will be still more ready to attack the guilty. And before those whose main occupation is with their neighbours' failings - people like satirists and writers of comedy; these are really a kind of evil-speakers and tell-tales. And before those who have never yet known us come to grief, since their attitude to us has amounted to admiration so far: that is why we feel ashamed to refuse those a favour who ask one for the first time - we have not as yet lost credit with them. Such are those who are just beginning to wish to be our friends; for they have seen our best side only (hence the appropriateness of Euripides' reply to the Syracusans): and such also are those among our old acquaintances who know nothing to our discredit. And we are ashamed not merely of the actual shameful conduct mentioned, but also of the evidences of it: not merely, for example, of actual sexual intercourse, but also of its evidences; and not merely of disgraceful acts but also of disgraceful talk. Similarly we feel shame not merely in presence of the persons mentioned but also of those who will tell them what we have done, such as their servants or friends. And, generally, we feel no shame before those upon whose opinions we quite look down as untrustworthy (no one feels shame before small children or animals); nor are we ashamed of the same things before intimates as before strangers, but before the former of what seem genuine faults, before the latter of what seem conventional ones.
The conditions under which we shall feel shame are these: first, having people related to us like those before whom, as has been said, we feel shame. These are, as was stated, persons whom we admire, or who admire us, or by whom we wish to be admired, or from whom we desire some service that we shall not obtain if we forfeit their good opinion. These persons may be actually looking on (as Cydias represented them in his speech on land assignments in Samos, when he told the Athenians to imagine the Greeks to be standing all around them, actually seeing the way they voted and not merely going to hear about it afterwards): or again they may be near at hand, or may be likely to find out about what we do. This is why in misfortune we do not wish to be seen by those who once wished themselves like us; for such a feeling implies admiration. And men feel shame when they have acts or exploits to their credit on which they are bringing dishonour, whether these are their own, or those of their ancestors, or those of other persons with whom they have some close connexion. Generally, we feel shame before those for whose own misconduct we should also feel it - those already mentioned; those who take us as their models; those whose teachers or advisers we have been; or other people, it may be, like ourselves, whose rivals we are. For there are many things that shame before such people makes us do or leave undone. And we feel more shame when we are likely to be continually seen by, and go about under the eyes of, those who know of our disgrace. Hence, when Antiphon the poet was to be cudgelled to death by order of Dionysius, and saw those who were to perish with him covering their faces as they went through the gates, he said, 'Why do you cover your faces? Is it lest some of these spectators should see you to-morrow?'
So much for Shame; to understand Shamelessness, we need only consider the converse cases, and plainly we shall have all we need.