The American military intervention in Afghanistan and then in Iraq has had two declared objectives: the first and more immediate, to deter and defeat terrorism; the second, to bring freedom, sometimes called democracy, to the peoples of these countries and beyond.

The sponsors and organizers of terrorism are of two kinds, with very different purposes, even though they can and frequently do cooperate. One of the two is local or regional, and consists of survivors of the former Iraqi regime, encouraged and supported by the governments of other countries in the region that feel endangered by what might happen in Iraq. The aim of these groups is to protect -- or, in the case of Iraq, restore -- the tyrannies under which these countries have lived so long. If, as many urge, the Americans decide to abandon this costly and troublesome operation and simply go home, this might just possibly be enough to satisfy the local sponsors of terror. Some of them might even offer the resumption of what passes for friendly relations.

But there are others who would see the eviction of the Americans from Afghanistan and Iraq not as the end but as the beginning -- as a victory not in a war but in a battle, one step in a longer and wider war that must be pursued until the final and global victory.

The Americans too, have proclaimed a larger and longer purpose for their intervention; not just to defeat and end terrorism, but to give to the long-oppressed peoples of Afghanistan, Iraq and eventually other countries the opportunity to end the corrupt and oppressive regimes under which they have suffered for decades, and to restore or create a political order respected by and answerable to the people. This goal evokes strong support among many in the region. But, because of both past experience and current discourse, that support is understandably wary.

Certainly, the creation of a democracy in the Middle East will not be quick or easy, any more than it was in Europe or the Americas. There, too, it must come in gradual stages. Going too far, too fast would give an immediate advantage to those skilled in the arts of manipulation and of intimidation. As the example of Algeria demonstrates, it can even lead to a violent clash between the two.

The kind of dictatorship that exists in the Middle East today has to no small extent been the result of modernization, more specifically of European influence and example. This included the only European political model that really worked in the Middle East -- that of the one- party state, either in the Nazi or the communist version, which did not differ greatly from one another. In these systems, the party is not, as in the West, an organization for attracting votes and winning elections. It is part of the apparatus of government, particularly concerned with indoctrination and enforcement. The Baath Party has a double ancestry, both fascist and communist, and still represents both trends very well.

But beyond these there are older traditions, well represented in both the political literature and political experience of the Islamic Middle East: traditions of government under law, by consent, even by contract.

Changes in the spirit of these traditions would offer an opportunity to other versions of Islam besides the fanatical and intolerant creed of the terrorists. Though at present widely held and richly endowed, this version is far from representative of mainstream Islam through the centuries. The traditions of command and obedience are indeed deep-rooted, but there are other elements in Islamic tradition that could contribute to a more open and freer form of government: the rejection by the traditional jurists of despotic and arbitrary rule in favor of contract in the formation and consensus in the conduct of government; and their insistence that the mightiest of rulers, no less than the humblest of his servants, is bound by the law.

Another element is the acceptance, indeed, the requirement of tolerance, embodied in such dicta as the Quranic verse"there is no compulsion in religion," and the early tradition"diversity in my community is God's mercy." This is carried a step further in the Sufi ideal of dialogue between faiths in a common search for the fulfillment of shared aspirations.

The attempt to bring freedom to the Middle East evokes two fears: one in the U.S. and still more in Europe, that it will fail; and the other, among many of the present rulers of the region, that it will succeed.