Fighting a Defensive War
And you shall put into the breastplate of judgment the Urim and the Tumim (28:7)
Rashi explains that they wrote the four-letter name of G-d and placed it inside the folded breastplate, and when they would ask a question, G-d would answer by causing the letters of the breastplate to light up. The Urim and Tumim were consulted most often before a war, to ask whether to fight, how to fight, or which tribe should go first. In fact, the Gemora in Berachos 3b teaches that King David always asked permission of the Urim and Tumim before he fought a war. He also consulted with the Sanhedrin and with his adviser Achisofel.
The Rambam in his Laws of Kings, chapter 5, says that asking the Sanhedrin (he does not mention the Urim and Tumim) is only necessary in a voluntary war, a war undertaken to enlarge the boundaries of the Jewish people. But in an obligatory war the king may go to war without consulting the Sanhedrin, at any time he wishes. And which wars are considered obligatory wars? The war against the seven Canaanite nations, the war against Amalek, and a war to defend the Jewish people from its enemies.
Not only does the king not have to ask permission from the Sanhedrin to fight a defensive war, but even in our times, during exile, when we have no king or Sanhedrin at all, it is sometimes allowed for Jews to fight such a war. We read about this in Shulchan Aruch, in the laws of Shabbos, Orach Chaim 329:6: "If gentiles are besieging Jewish cities, if they are coming to take money, we may not violate Shabbos to fight them, but if they are coming to kill, or if they are coming without any stated purpose, then we may go out and fight them with weapons and violate Shabbos. And if the city is near the border, even if they come only to steal straw, we may violate Shabbos to fight them. Rema: Even if they have not yet come but are planning to come, we may prepare ourselves."
It can be proven that this law applies even during exile, because its source is in Eiruvin 45a, and there the Amoraim, who lived during exile, explain how it applies to their cities in Babylonia. Babylonia contained a large area that was full of Jewish cities and villages, and the city Nehardea was near the border of this area. If gentiles invaded Nehardea for any reason, say the Amoraim, it would be permitted to fight them on Shabbos because it is a border city.
Some Jews admit that the Zionist state is forbidden, but justify its wars on the grounds that they are defending Jewish lives. But there are three fundamental errors here: 1) The gentile nations who fight the Zionists are fighting because they wish to control the land instead of the Zionists. Thus the Zionists are fighting not to defend Jewish lives, but to defend their statehood and their political control of the land. Since the Three Oaths forbid statehood and political control over the land during exile, it follows that any war fought to maintain that statehood is also a violation of the oaths. 2) Most of the Zionists' wars were not defensive; the Zionists were the ones who initiated hostilities. 3) The Shulchan Aruch is talking about Jews fighting to defend their host country against outside attackers. They are defending a Jewish city that is part of a non-Jewish country, and thus they are fighting not as Jews but as citizens of that country. In other cases, they are defending themselves against criminals in a non-Jewish country whose government would like to control crime. Thus they fight as a service and assistance to their government. But there is no permission for Jews during exile to fight against the gentile nations among whom they live; that is a violation of the Oaths.