So many government efforts run aground on problems with poor incentives. When the U.S. government intervenes overseas, those poor incentives are compounded by trying to impose Western values and institutions, usually by force, on peoples with starkly different cultural values, customs, and ways of doing things. Such was the case with failed U.S. interventions in Vietnam, Lebanon, Somalia, and Iraq.

And then there are those government efforts overseas that don’t make any sense at all. The U.S. military’s social-work project in Afghanistan is one of them. Unlike the invasion of Iraq, which was conducted to remodel Saddam Hussein’s dictatorship into a Western-style democracy that would be the envy of the Middle East, the war in Afghanistan was supposed to be designed to cripple the 9/11 attackers and make their Afghan sanctuary unusable for terrorism in the future.

Unfortunately, the U.S. government felt that the best way to do the counterterrorism mission was to expand the effort into remodeling Afghanistan into a Western-style democracy. To tame this wild land, more and more foreign troops were needed. Non-Muslim occupation of Muslim land—also a source of past and present conflicts in Palestine, Chechnya, Iraq, and Afghanistan during the three failed British attempts and one failed Soviet attempt to subdue the country—led to a resurgence of the Taliban. The Western mind cannot understand why a significant number Afghans would support the return of these brutal thugs (no insurgency as strong as the Taliban can survive without significant public support). But the answer lies in the fact that foreign occupiers, especially non-Muslim ones in this conservative Islamic country, are never given the benefit of the doubt, even if they hand out candy to local kids.

But the U.S. government’s situation in Afghanistan has been more convoluted than in most such nation-building counterinsurgency campaigns. The central problem with the war in Afghanistan is Pakistan. In exchange for billions of dollars in U.S. aid to this financially ailing country, the Pakistanis are supposed to provide bases for drones in what remains of the war against al-Qaeda and the principal transit route for supplies going to U.S. and allied counterinsurgency forces in Afghanistan. The United States also hoped the Pakistanis would pressure the Taliban into negotiating an end to its insurgency.

But after the killing of Osama bin Laden on Pakistan’s soil embarrassed that government and U.S. airstrikes inadvertently killed 24 Pakistani soldiers, anti-American rage in Pakistan compelled the government to close U.S. drone bases and the supply route into Afghanistan. U.S. soldiers burning Qurans, urinating on Taliban corpses, and massacring Afghan civilians further fueled anti-Americanism in the Af-Pak region.

The U.S. had hoped the Pakistani government’s closure of the supply route would be temporary, but the continuing anti-Americanism has compelled the Pakistani government to demand the end of drone attacks (which now have to be conducted from Afghanistan and are aimed at a few remaining al-Qaeda fighters, Afghan and Pakistani Taliban, and other militants) in exchange for a reopening of the supply route.

To make matters worse in this complicated mess, America’s ostensible allies—the Pakistanis—have not only not been pressuring the Taliban to negotiate, but they have also been aiding the insurgency. Because American military aid still continues to flow to Pakistan, the United States has essentially been aiding both its allies and its enemies in the Af-Pak region. Because Pakistan worries about being sandwiched between its archenemy, India, and an Indian-influenced Afghanistan, it has continued, and has no incentive to quit, helping its traditional Taliban allies against the United States.

The recent shenanigans by American troops have put pressure on the Obama administration to move up the scheduled withdrawal of American forces from 2014. Of course, this is the solution to most of the U.S. problems in the war, but so far, President Obama has resisted such action.

After a more rapid and complete American withdrawal from Afghanistan, the Americans would hold a better hand vis-à-vis the Pakistanis: they wouldn’t need a supply line or drone bases and could threaten to cut off aid if the Pakistanis didn’t pressure the Taliban to negotiate a postwar settlement for Afghanistan. Even if the U.S. wanted to retain drone bases in Pakistan to fight al-Qaeda, it would have a better negotiating position to get them, especially if it threatened to end aid and instead use other nearby countries for the bases. The U.S. likely would have to exchange some role in the Afghan government for the Taliban—perhaps even Taliban control of that country—for the group’s promise not to provide a sanctuary for al-Qaeda.

As of now, according to U.S. intelligence, there are few al-Qaeda in the region, and a “no sanctuary” agreement with the Afghan Taliban could keep it that way. The Taliban and al-Qaeda don’t get along very well, and the Taliban have suffered greatly for providing a past safe haven for the group. America usually doesn’t believe its adversaries can learn; they can.

Thus, withdrawing from Afghanistan more rapidly would make America less beholden to Pakistan and allow the U.S. to greater leverage its aid to ensure the Taliban no longer provides a safe haven for any remaining al-Qaeda fighters—which should be the only goal in this volatile region. Unfortunately, the Obama administration is not there yet, with talk in some quarters of leaving some American troops in Afghanistan past the 2014 withdrawal date. But in an election year, growing American public pressure to bring U.S. troops home will perhaps nix an idea with the dangerous potential for a future American re-escalation of the conflict.