"War is strategy." الحرب خَدْعة
As narrated by Jabir Ibn Abdullah, the first time the prophet said these words was during the battle of Al Ahzab (the trench). This was his way of encouraging his followers to develop a sense of strategy as opposed to relying solely on physical resources. It's also his way of warning them about the tricks and deceptions being used by the enemies. To this effect, he also said in another Hadith that "a believer is not bitten from the same hole twice." Furthermore, he's bringing their attention to the importance of mutual consultation which is a prerequisite for good strategy. One could win the most difficult war by using a well thought out and planned strategy.
A strategy could be used at times of confrontation between Muslims and their enemies or in preparation thereof. However, being a religion that upholds the highest standards of moral and justice, Islam completely prohibits breaking a covenant or treaty or resorting to betrayal, regardless of the intended outcome. Throughout the biography of the prophet, we find many instances illustrating how this important concept was properly implemented.