The rebel commander, his face hidden behind a dark turban, leads the way over the soft sand, scorched black in places by exploded mortar shells and littered with detritus from a series of battles waged here, on a children's soccer field.

With nearly every stride, our feet crunch spent rifle cartridges. "Step in my steps," he cautions, noting that the Niger army had mined the area, where there had been a school for Tuareg. His men removed some of the devices; others remained lost in the shifting sands. "Maybe they are buried too deep to explode if you step on one."

It is late afternoon in the dry season, and the temperature has finally slipped below 100°F. The beige dunes stretching to the north begin to take on a pink hue, and the shadows from the steep ridges to the southwest are spreading across the valley floor. In this lonely valley called Tazerzaït, where the Aïr Massif meets the great sand seas of the Sahara, the commander's men had won the greatest victory of their two-year rebellion against the Niger government.

The rebels, all ethnic Tuareg, descend from the fierce nomads who for several centuries dominated the lucrative caravan trade in gold, spices, and slaves that crisscrossed this desolate region of North Africa. Fighting under the banner of the Movement of Nigeriens for Justice (MNJ) and supported in part by Libyan leader Muammar Qaddafi, they had captured 72 government soldiers at Tazerzaït and renewed their demands that the government share revenue derived from another source of treasure: uranium mined on Tuareg lands. In a show of goodwill the Tuareg released all of their prisoners—except one. "He is a war criminal," the commander says.

As we walk, the commander explains that local Tuareg built the school at Tazerzaït because it is near a well central to the region's far-flung grazing areas, allowing families to visit their children as they moved their herds. Previously, locals who wanted their children educated had to send them to far villages and rarely saw them.

"My father only knew how to live in the desert," the commander says. "He knew how to make the salt caravan to Bilma, how to find grazing in the desert, how to hunt antelope in the canyons and wild sheep in the mountains. And that is what I know, but the life of the desert is ending. Our children need school."

We reach the top of a small bluff where three mud-brick classrooms stand, their walls gouged with bullet holes, their roofs missing. The chalkboards are covered with graffiti left by the Nigerien soldiers—French profanities and cartoons depicting Tuareg having sex with animals.

Four rebels with Kalashnikovs slung over their shoulders have brought the alleged war criminal down from the mountain cave where they are holding him. His posture is slumped, like a sulking teen, and he crosses and uncrosses his arms, eyes darting among the men. The sleeves of his camouflage shirt are cut off and his combat boots are untied. He claims to be 27 years old, but his round face and awkward manner make him look much younger.

It is growing late, and the rebels are edgy about lingering in this exposed position. The Niger army had countered its defeat on the ground by acquiring helicopters, and the rebels had recently been surprised by an assault from the air that killed several men, including one of their leaders. The men squint toward the horizon, and periodically everyone goes silent to listen for the sounds of blades beating the air. "They buy helicopters to fight us, but they will not build schools or wells for us," the commander says, as he leads the way to the edge of the school grounds. The prisoner trails behind, his head bowed, bootlaces skipping along the ground. The commander stops at a place where stones set in the soft sand mark out three graves.

"Three old men are buried here," the commander says. "When the army attacked," he points to one of the graves, "this man, who was blind, refused to flee." He motions to the other graves. "These two refused to leave him." He describes how the soldiers accused the old men of helping set land mines. "That night they tortured them behind the classrooms. We were hiding in the mountains, just there," he says, gesturing to a ridgeline above us. "We could hear the old men screaming." He spoke quietly. "This one," he points to the grave in the center, "is my father."

To reach this remote corner of the world's largest desert requires traversing a vast primordial landscape—a place defined by salt pans that take the better part of a day to cross, dune fields that rise and fall like violent seas, and mammoth outcroppings of glassy marble and obsidian that breach the sand like extinct sea creatures. Countless generations of Tuareg warriors ruled this realm, demanding tribute from merchants plying the caravan routes and raiding sedentary tribes along the Niger River for animals and slaves. Guided by the proverb "Kiss the hand you cannot sever," the Tuareg gained a reputation for brutality and treachery, often robbing the very caravans they were hired to protect and launching surprise attacks on their allies.

At the turn of the 20th century, the Tuareg were the last of the West African peoples to be pacified by the French, and their lands were absorbed into parts of Niger, Mali, Algeria, and Libya. Those governments generally ignored their fractious Tuareg minorities, leaving them to wander the desert with their flocks of camels and goats. But in recent decades, as less and less rain fell during the wet seasons, Tuareg families struggled to sustain sizable herds. "Animals are everything to a Tuareg," an elderly nomad once explained to me. "We drink their milk, we eat their meat, we use their skin, we trade them. When the animals die, the Tuareg dies."

With their herds declining, many Tuareg in Niger began asking why the government wasn't sharing the wealth derived from the rich uranium deposits that for decades have been mined from their grazing lands. During the 1990s a Tuareg militia, many of its members trained and armed by Qaddafi, fought the Niger army over the issue. A peace accord was signed, but little changed. In 2007 the government was negotiating contracts with France projected to make Niger the world's second largest uranium producer. More deals allowed foreign companies to explore the desert for other resources. With the nation mired in poverty and the government refusing to make meaningful investments in Tuareg-dominated areas, the nomads rebelled again. Meanwhile, drug smugglers and a North African offshoot of al Qaeda established themselves in the region, and the Niger government accused the Tuareg of being involved with them.

The rebels make camp for the night in a dune field a few miles from the school, hiding their battered pickups under the low canopies of acacia trees. Several men wash their hands and faces with water from teakettles and kneel toward Mecca for evening prayers. Then they gather in clusters of six or seven, each group taking shelter behind a small dune and kindling a meager fire.

A few of the rebels wait for full darkness to unwind their turbans. By tradition Tuareg men cover their faces, though the women do not. The layers of cloth not only protect from the harsh sun and wind but also conceal their emotions. Like mummies coming back from the dead, their animated faces emerge in the firelight, revealing downy wisps of beard and boyish grins. Some of their cheeks are stained with indigo dye from their turbans, an age-old mark of the Tuareg that led early visitors to dub them the "blue men."

The rebels' medic invites me to join his group. They tease each other and light cigarettes as they boil macaroni and brew tea. Many appear barely old enough to have undergone the traditional postadolescent ceremony in which their uncles pronounce them ready for manhood and twist the first turban around their heads.

By the fire I notice that the medic and another man bear the common ethnic features of the African interior—dark brown skin, kinky hair, and broad noses. Two men have olive complexions, smooth black hair, and sharp Mediterranean noses. The other three are a mixture of all the traits. Regardless of skin color, a surprising number have topaz blue eyes. This genetic grab bag suggests one of the riddles of the Tuareg, who have always considered themselves a people apart yet for centuries took slaves from other desert tribes and intermarried with them. The result is an ethnic group distinguished primarily by its common language, Tamashek, which is related to Berber tongues spoken in Algeria and Morocco.

We huddle around a communal bowl, sharing spoons to dip out mouthfuls of salty macaroni seasoned with desert herbs. The men eat hungrily but are careful to take only their portion. Between bites, the medic tells me he was a doctor's assistant before the rebellion. His left eye, a blank, milky orb, is a casualty of his very first battle. Next to him sits the group's thick-shouldered machine gunner, who mans a .50 caliber with a rusting barrel. He says he left engineering classes at a university in Nigeria to join the rebels. "I could not study while my Tua­reg brothers were fighting," he tells me.

Hama, a lanky youth, has never gone to school. He grew up in an Aïr village, making the annual camel caravan with his father. He points to the brightest stars and describes how to use them to navigate to the Bilma oasis in the eastern desert, where they would trade onions and garlic for salt. "Thirty days by foot," he says, noting that the first time, he made the trip barefoot.

I ask who is the youngest, and the medic points to a painfully shy boy named Bachir. Almost whispering, Bachir says he thinks he is about 17 but isn't sure. He was tending his family's animals in the mountains when a rebel convoy drove by, and he asked to join them. "He is good luck," one of the men says. After gentle prodding, Bachir recounts how he was riding in the back of a pickup when it struck a mine. Two men died instantly, eight suffered serious wounds, but Bachir was hurled a hundred feet away into the top of an acacia tree. "It felt like I went to sleep and woke up in the branches, and everything was silent," he says quietly.

The rebels were searching for his body among the smoking wreckage when he walked up. "He wasn't even scratched by the branches," the medic says, his good eye widening. "Allah has his hand on that one." The other men click their tongues, using the Tuareg shorthand for agreement.

I ask Bachir what he will do after the rebellion, and he replies that he would like to be a soldier. "In the Niger army?" I ask. At the end of the last Tuareg rebellion in 1995, many former rebels were brought into the Niger military as part of the peace settlement. "You would join the people who have killed your friends and nearly killed you?" He shrugs: "I think it would be a good job." Some of the others click their tongues.

Soon after dinner the prisoner is brought to me, and we are allowed to talk privately. He is a Fulani, one of the ethnic groups that the Tua­reg once raided for slaves. He says he is Abdul Aziz, a lieutenant in the Niger army. He admits to shooting one of the old men in the leg. "It was wrong of me to do this," he says. His superiors were angry that two of their vehicles had struck mines laid by the rebels, killing and wounding several men. To evacuate the injured, the army would have to pass through the rebel minefield again, and they were convinced that the old men knew where the explosives were laid.

"The officers asked the old men to talk, but two of them refused. The one who was shot was talking, but he wasn't giving good information. It was getting to be night. That's when I left," the prisoner says. "I will swear on the Koran that I did not kill any of them."

After he and the other soldiers were captured, his superiors made him the scapegoat, he says. His Tuareg captors had never beaten him and had allowed him to receive a letter from his parents via the Red Cross at the end of Ramadan. "All of us are Nigeriens," he says. "It is only Satan who creates a problem between people."

As the night deepens, the older rebels gather at the commander's fire, where the flames have dwindled to coals. The men stretch out on quilts and pass around cigarettes and small glasses of hot sugared tea. The air is cool and sweet, and the dunes glow under the oval moon. One man produces a guitar. The lowest bass string was broken and replaced with a motorcycle brake cable, giving certain chords a resonant buzz. "Do you know Tinariwen?" the guitar player asks, referring to a Tuareg band whose founders had trained together in Libyan military camps during the 1980s. He begins to play one of their songs. "It is about the Tuareg struggle," another rebel says.

A few at the fire had trained in the Libyan camps. As teenagers they had heard radio broadcasts of Qaddafi sympathizing with the plight of the Tuareg and exhorting them to come to Libya, where he would help them fight for their rights. But soon after joining one of his training camps, they realized the Libyan dictator was using them. Some were sent to fight in Lebanon; others saw action when Libya invaded Chad.

"We also used Qaddafi," one rebel says, noting that Tuareg from Mali and Niger had smuggled weapons from the camps to fight their governments at home. In recent years Qaddafi sent millions in economic aid to leaders in Mali and Niger while funneling support to Tuareg groups fighting against them. "Our leader is in Tripoli now," the commander says, referring to Aghali Alambo, the MNJ's president.

I ask the commander about the Niger government's charges that the rebels are an ally of al Qaeda and involved in drug smuggling. He motions at his bedraggled platoon. "Do we look like rich smugglers?" The other men click their tongues.

The singing continues, more glasses of tea are poured, and stories are told. One rebel quietly confides that the men are suspicious of their leader, Alambo. "There are rumors he has a villa in Tripoli," the man says. "We have strong vehicles and many weapons. We want to fight, but when we make a plan to attack, Alambo always says no. No one understands what he is waiting for."

The next day I am to travel farther into the mountains to join another group of Tuareg rebels. "You will see," the man says. "The Tuareg there will say bad things about us—that we are not fighting, that we will betray them, that our leaders are corrupt." He sighs. "There is always disagreement among the Tuareg. It is our curse."

Several weeks after I left the Aïr, the commander released the prisoner. In the ensuing months the rebels and the government announced a cease-fire, and not long afterward the Niger army overthrew the country's strongman president, Mamadou Tandja, and held free elections. Last February, with democracy protests mounting in Tripoli, Qaddafi sent recruiters to Niger and Mali with offers, reportedly as high as a thousand dollars a day, to any Tuareg who would come fight for his regime in Libya. Tuareg sources in Niger say that some former members of the MNJ have taken the offer.

Upon hearing this news, I recalled one of my last conversations with the rebel commander. He had driven me to a place in the desert where I would depart from his territory. He gave me some dried sheep's cheese and said he wanted to send me with the message that if the world wanted to stop the growing threats of al Qaeda and drug smuggling in the Sahara, they needed to enlist the Tuareg. "The desert has no secrets from the Tuareg," he said, repeating a favorite local aph­orism. "We know how to fight here better than anyone." Yes, I said, but given the Tuareg history of betrayal and infighting, could the West trust them? He answered with a click of his tongue. I couldn't gauge his expression because his face was completely obscured by his turban.