Well that, of course, is what all the debate here is ultimately about.
The classic formulation comes from the Caroline incident, in which (ironically) the US was the victim of a measure of pre-emptive self-defence (by the UK, from the then colonial Canada). The US Secretary of State of the time formulated two conditions necessary to justify pre-emptive self-defence which, since them, have come to be very widely accepted. They are
(a) pre-emptive self-defence is only justifed where “the necessity of that self-defense is instant, overwhelming, and leaving no choice of means and no moment for deliberation,” and
(b) the force used must not be “unreasonable or excessive”, the “act justified by the necessity of self-defence must be limited by that necessity, and kept clearly within it.”
On the face of it, it would be hard to bring the US action in Iraq within a simple application of those principles. The war was months in preparation; it cannot be said that the necessity of self-defence was “instant” and left no “moment for deliberation”. Nor, indeed, was there much evidence offered, then or now, that Iraq was contemplating an attack with WMDs on the US or on US forces.
But the Caroline case dates from the middle of the nineteenth century and, as you say, international terrorism (or, of more relevance, weapons of mass destruction) were not really in contemplation. How are those principles to be extended and applied today?
The issue arose when Israel bombed an Iraqi nuclear reactor in (I think) 1981. The international community generally condemned that action as illegal. A Security Council resolution condemned the attack as a clear violation of the UN Charter (which allows the use of force in self-defence) and, signficantly, the US did not veto the resolution – a very rare thing for the US at that time. As late as 1981, therefore, the US did not appear to consider that the development or suspected development of WMDs by a hostile state (Iraq was formally at war with Israel at the time) justified “pre-emptive self-defence”. Clearly, the US does consider that now, but it’s less clear that the international community at large accepts that view.
Probably the fairest thing that can be said is that a traditional understanding of the pre-emptive defence principles would certainly not cover the kind of measures undertaken here. In modern conditions, however, it is legitimate to ask whether the possession of weapons of mass destruction, coupled with an intention to use them against another state, should justify pre-emptive self-defence, and whether the principles of international law should be extended to cover that case. Iraq might have provided a useful case for this development, were it not for the fact that
(a) it doesn’t now appear that Iraq had any weapons of mass destruction, and
(b) there isn’t a huge amount of evidence for its aggressive intentions towards the US either (as opposed to political antipathy for the US, which Saddam had in spades, but which is certainly not a justification for war).
The second plank on which the US relied to justify the war was the terms of Security Council resolutions adopted in 1990 and 1991. That justification isn’t really cast-iron either, but at this stage it does look like the stronger of the two.
The Congressional Research Service – presumably not a source biassed against the United States – has published a useful paper on this subject which I found here: http://www.usembassy.at/en/download/pdf/iraq_intlaw.pdf