The policy of striking a nation that you fear might be contemplating hostile actions is called preemption.
You are declaring a preemptive war on that country so as to stop them from making any hostile actions they may or may not have wanted to make. This can be both a good and a bad thing - it is good if that country really wanted to start a war or something like that, but it can be a bad thing if they never intended to do such a thing.