There is no "greater good" that ever legitimizes the killing of innocent civilians. For once you start down that road it will never end. Hamas bombed Israeli civilians "for the greater good" them the Israeli went on and did the same to a school, also for the "greater good". Don't you see to where it leads?
And worse because all those affected by these acts of terror are scared mentally for life. Scares which will be pased on for at least 2 or 3 generations if not longer. My grand father barely survived the Japanese Birma WWII POW slave camp and my father the women and children camp so I know first hand what it did to him and then to me. I almost missed out on having children out of fear of passing it on.
All wars are sad failures. They represent huge set backs of our evolutionary trajectory into becoming an intelligent specie.