What is the justification for the typical punishment of a student who did not cheat but helped others cheat?
Probably the main issue that makes this policy logical is that when two students are caught communicating during an exam, there is no foolproof way for the instructor to tell who copied from whom. The communication may have been one-sided, or it may have been two-sided, or it may have been one-sided but in the opposite direction than what the instructor suspects. Thus, by the mere act of exchanging information with another student, in any direction, the student undermines trust in the value of their own exam as an indication of their knowledge. Giving them a failing grade is the only policy that guarantees that they will not get away with getting illicitly-earned points. Since as you yourself said, some form of punishment is definitely logical, giving that specific punishment becomes logical both as a deterrent and as a defense against a student getting away with copying.

In other words, the policy makes perfect sense, and is pretty much the only rational way for universities to address cheating on exams.