At a recent hearing a congressman began his questions to American top brass by sputtering, "I can't believe that our wonderful soldiers would do anything to hurt American foreign policy." It was a stunningly naive remark, a product of several decades of civilians' guilty consciences about their treatment of Vietnam veterans and of the gradual isolation of American elites from the reality of military service. The horrors of Abu Ghraib were not of themselves part of the price paid for the end of the draft, but perhaps the bewilderment of Americans who admire the military from afar is.

Military service, or a life spent with soldiers, brings one to the realization that soldiers, like the rest of us, fall on a continuum, a normal distribution of most human virtues and vices. At the right end of the curve lie men and women of extraordinary physical, mental and indeed spiritual distinction; people of exceptional character, whose fortitude, largeness of spirit and greatness of soul leave one humbled. The armed forces also have the others -- the liars, petty tyrants, place-hunters, opportunists, even, yes, the cowards and the brutes. By and large military service excludes or winnows out most of the latter, attracting and retaining far more of the former; it has a higher concentration of the finer types than any other walk of life that I know. But despite its best efforts, it has its share of moral weaklings and scoundrels.

Military sociology has at its core two powerful insights. First, military organizations reflect in many ways the societies from which they emerge. If a society condones brutality and lewdness, you will find soldiers beating prisoners and copulating with one another while their comrades take souvenir snapshots. If a society has no norm of chief executives accepting responsibility for their corporations' moral and financial failures, do not expect generals to line up to say: "It happened on my watch, and I therefore offer the secretary of defense my resignation." In some measure, societies get the militaries they deserve.

Second, to control the use of violence amid the terrors and hardships of war, armed forces must create unusual institutions, mores and habits. When the country sends men and women to war, it asks them to endure physical and mental misery -- heat, dust and hard labor on the one hand, separation from home, boredom and fear on the other. Government equips these men and women with devastating weapons, and even when it attempts to limit their use of force, it must give them great discretion. Unless subjected to thorough training, relentless discipline and solid leadership, normal products of our society -- individualistic, hedonistic, often unreflective and rarely far-sighted -- will act badly. For that reason, Abu Ghraib reflects not merely the actions of a few sadists who somehow slipped through the net but a broader failure of military leadership.

It is up to the secretary of defense and our top generals to restore the situation, through legal processes, administrative action and their own qualities of leadership. One looks not only for courts-martial but for administrative dismissals and resignations. The vast majority of U.S. troops in Iraq and Afghanistan have conducted themselves honorably and courageously, but let us not pretend that the failures here reflected only the misdeeds of an inexplicable few.

We civilians also have our lessons to learn. The first is that the costs of war extend beyond the caskets coming home to Dover and the broken bodies in Walter Reed, to the moral hazards imposed on young people dispatched to further American policy by force of arms. The second is the imperative of standing behind responsible civilian and military leaders when they insist on the highest standards of conduct for military personnel. Not long ago a Senate majority leader reproached the chief of staff of the Air Force for his service's seemingly harsh treatment of a young officer who seduced the husband of one of her subordinates. Gen. Ronald R. Fogleman, however, understood what Sen. Trent Lott did not, namely, that only a fragile wall of discipline and integrity separates honorable warriors from barbarians.

The third and hardest lesson is that the torture and abuse at Abu Ghraib should cause us to look harder at ourselves. The military holds up a mirror to our society; the shadows are, at times, deeper, but fortunately the lights often gleam more brightly. Nothing makes that clearer than the tale of two Army specialists. Charles A. Graner Jr.'s evil leer at Abu Ghraib belonged to an American soldier. Pat Tillman's quiet heroism on an Afghan battlefield did also. One faces trial, while the other, who forsook wealth and fame for a private soldier's anonymity, lies in a patriot's grave. We owe to the latter not only an honored memory but a sober appreciation of where each fits in the American story.

The writer is Robert E. Osgood professor of strategic studies at Johns Hopkins University's School of Advanced International Studies.