Now Israel remained in Acacia Grove, and the people began to commit harlotry with the women of Moab. They invited the people to the sacrifices of their gods, and the people ate and bowed down to their gods. So Israel was joined to Baal of Peor, and the anger of the LORD was aroused against Israel.
Then the LORD said to Moses, “Take all the leaders of the people and hang the offenders before the LORD, out in the sun, that the fierce anger of the LORD may turn away from Israel.”
So Moses said to the judges of Israel, “Every one of you kill his men who were joined to Baal of Peor.”
And indeed, one of the children of Israel came and presented to his brethren a Midianite woman in the sight of Moses and in the sight of all the congregation of the children of Israel, who were weeping at the door of the tabernacle of meeting. Now when Phinehas the son of Eleazar, the son of Aaron the priest, saw it, he rose from among the congregation and took a javelin in his hand; and he went after the man of Israel into the tent and thrust both of them through, the man of Israel, and the woman through her body. So the plague was stopped among the children of Israel. And those who died in the plague were twenty-four thousand.
Then the LORD spoke to Moses, saying: “Phinehas the son of Eleazar, the son of Aaron the priest, has turned back My wrath from the children of Israel, because he was zealous with My zeal among them, so that I did not consume the children of Israel in My zeal. Therefore say, ‘Behold, I give to him My covenant of peace; and it shall be to him and his descendants after him a covenant of an everlasting priesthood, because he was zealous for his God, and made atonement for the children of Israel.’ ”
Now the name of the Israelite who was killed, who was killed with the Midianite woman, was Zimri the son of Salu, a leader of a father’s house among the Simeonites. And the name of the Midianite woman who was killed was Cozbi the daughter of Zur; he was head of the people of a father’s house in Midian.
Then the LORD spoke to Moses, saying: “Harass the Midianites, and attack them; for they harassed you with their schemes by which they seduced you in the matter of Peor and in the matter of Cozbi, the daughter of a leader of Midian, their sister, who was killed in the day of the plague because of Peor.”