To cause harm to one's enemies, and to help one's friends. Given your reading of Ajax which characters follow this moral code, which don't?
This question appears to be prompted by a reading of Mary Blundell's book Helping Friends and Harming Enemies: A Study in Sophocles and Greek Ethics. According to the traditional Greek code of Greek ethics, it was customary to help one's friends, but harm one's enemies. In Sophocles' Ajax, though, the tragedian explores what happens when one's friends become one's enemies.
For example, Ajax's consort, Tecmessa, was a Trojan woman who was now the mother of a Greek man's son. Even though Ajax had destroyed Tecmessa's homeland, Tecmessa now seems to care for Ajax. Thus, she does not appear to embrace the traditional value. She cares for her enemy.
In this play, however, the most prominent blurring of the lines between friend and enemy comes when Ajax tries to kill his fellow Greek soldiers, Agamemnon, Menelaus, and Odysseus. Thus, Ajax's friends become his enemies. Agamemnon and Menelaus follow the traditional code by wanting to harm Ajax. Odysseus, however, feels sorry for Ajax, even though Ajax tried to kill him.
All the same, although he despises me,
I pity his misfortune under that yoke
of catastrophic madness. It makes me think
not just of his fate but my own as well. (Ian Johnston translation)
Thus, Odysseus does not follow the traditional code of values. This becomes even more pronounced later on in the play after Ajax has killed himself, ironically, with the sword of his enemy Hector. After Ajax's death, Agamemnon and Menelaus continue to cling to the traditional code of values by denying Ajax a proper burial. Odysseus, on the other hand, argues against his "friends" and persuades them that his "enemy" deserves a proper burial.
Interestingly, even after Agamemnon and Menelaus yield to Odysseus, who has paved the way for Ajax's burial, Ajax's half-brother Teucer, despite being thankful for Odysseus' help, will not allow Odysseus to assist in the burial because it is not what Ajax would want.
But you, child of venerable Laertes,
I hesitate to let you touch the corpse
in these funeral rites, for that may well offend
the man who died.
Thus, even in death, Ajax clings to the traditional code of values. He still hates Odysseus, even though Odysseus was instrumental in arranging for his burial.