How does stating that Pinchos was descended from Aharon help matters?
(25,11) “Pinchos the son of Elazar the son of Aharon the Kohen has turned away My wrath from upon the Children of Yisrael when he avenged My vengeance among them, and I did not destroy the Children of Yisrael with My vengeance.”
Rashi brings the midrash which teaches that because the tribes disparaged Pinchos and said: Have you seen the son of Puti, the one whose mother’s father (Yisro) fattened calves for idols and who killed a prince of a tribe of Yisrael, therefore the Torah traces his genealogy to Aharon. But how does this help - it doesn’t change the fact that his mother’s father was an idol worshiper!
But we can explain the midrash according to the teaching in the gemora Yerushalmi which Tosafos brings in Sanhedrin 28a. The gemora asks that since closely related relatives cannot testify for one another, would Moshe have been allowed to testify for the wife of Pinchos - are they considered to be closely related because of the concept that a man and his wife are considered to be one entity? Tosafos concludes that since the gemora did not ask whether Moshe would have been allowed to testify for Pinchos himself it is clear that the Yerushalmi holds that a person cannot testify for a third generation relative - Moshe would not have been allowed to testify for his grand-nephew Pinchos.
But there is a difficulty with this Tosafos, because perhaps the gemora really holds that a person is allowed to testify for a third generation relative, and the reason why the gemora did not ask about Pinchos himself was because Pinchos was a second generation relative of Moshe - since both Moshe and Elazar married a daughter of Putiel (Yisro), Elazar was a first generation relative of Moshe, and thus Pinchos was a second generation relative. To answer this difficulty we must say that converts (the daughters of Yisro) are not considered related, and therefore Elazar was not a first generation relative of Moshe.
Now, the commentaries point out that the killing of Zimri by Pinchos was seemingly unlawful, because even though the law is that a zealot may kill someone who has relations with a heathen woman, he is only permitted to do so at the time of the incident, but after the incident he is forbidden to kill the sinner. And the gemora in Yevamos and Kiddushin teaches that if a Torah sage teaches a new law before an incident occurs to which the halachah is relevant then we listen to him, but if he teaches it after the incident (or at the time of the incident) then we don’t listen to him since we suspect that the incident might have caused him to err in the application of the law, and there is no one else who can testify for him that his teaching is correct.
If so, since the law that a zealot may kill someone who has relations with a heathen woman was a previously unknown law, who could have testified for Pinchos that his teaching was correct? Moshe was the only other person who knew about this law, but he was a close relative of his and so he would have been forbidden to testify for him. Therefore his killing of Zimri should have been unlawful!
We can answer this by saying that really a person can testify for a third generation relative, and so Moshe could have testified for him. However, this only true if we say that converts are not related, but if we say that converts are related the difficulty returns, because then Pinchos would have been a second generation relative of Moshe as we wrote above, and thus forbidden to testify for him.
we can understand what the midrash is teaching - the tribes disparaged
Did you see the son of Puti whose mother’s father fattened calves for
idols. That is, perhaps converts are considered related and
therefore Moshe is a second generation relative of Pinchos and thus
unable to testify for him. If so, Pinchos had no legal right to kill a
prince of Yisrael since there is no one to testify that his teaching
Therefore the Torah comes and traces his genealogy to Aharon in order to indicate that this is his true genealogy and not the connection to Yisro through his mother, because converts are not considered related. If so, Moshe was a third generation relative of Pinchos and therefore he could testify for him. Hence his killing of Zimri was completely lawful.
What does the Midrash mean when is says that Pinchos was justifiedly rewarded?
(25,12) “Therefore, say: I hereby give to him My covenant of peace.”
The midrash comments on this posuk that Pinchos justifiedly received his reward. This teaching is very difficult to understand - Hashem does not withhold the reward of any creature, so why does the midrash single out Pinchos?
We can answer this question with the teaching of the gemora in Kiddushin 39b that no reward is given for mitzvos in this world. The sefer Asarah Ma’amaros explains that the reason is because a mitzvah is eternal and therefore its reward must also be eternal. Therefore the reward cannot be given in this world, because if he is rewarded and then dies the reward will not have been eternal. Only after he dies will the reward be eternal.
And behold, it says in the Zohar that when Pinchos killed Zimri the whole tribe of Shimon gathered together and wanted to kill him, and the soul of Pinchos left him and the souls of Nadav and Avihu, the sons of Aharon, entered him in its place. This is the meaning of the previous posuk “Pinchos the son of Elazar the son of Aharon the Kohen”. Why does it say that he was the son of Aharon - surely he was the grandson of Aharon! But it means that even though he was (biologically) the son of Elazar, nevertheless, he was really the son of Aharon because he now had the souls of Nadav and Avihu.
We see from this that Pinchos had already tasted the taste of death and would not suffer any further death - Pinchos is identified as Eliyohu who lives forever. Thus we can now understand the meaning of the midrash which says that Pinchos justifiedly received his reward - he justifiedly received his reward in this world because for him the reward would be eternal even though it was given in this world.
A different way of explaining it is because the Torah says that wages are paid at the end of the earning period, and what is the end of man - his death. But Pinchos who is Eliyohu lives forever, and therefore we cannot say that he should be paid at the end since he has no end. Therefore, he justifiedly received his reward immediately.