Historians still debate whether President John F. Kennedy would have withdrawn U.S. troops from Vietnam had he lived to win re-election in 1964. Since President Barack Obama recently announced his intention to keep at least 8,400 U.S. troops in Afghanistan through the end of his presidency, the only debate will be over why he never withdrew but chose instead to bequeath an unwinnable war — the longest in U.S. history — to his successor.

The U.S. war in Afghanistan will officially pass the 15-year mark in a few months. But like Vietnam, where the United States began aiding French colonial forces in the late 1940s, Afghanistan has been the target of Washington’s war-making for more than three-and-a-half decades.

"So why doesn’t Obama just get out? That worked in Vietnam which Washington today is courting as an ally."

On July 3, 1979, President Carter first authorized the secret provision of aid to armed opponents of the leftist regime in Kabul. A senior Pentagon official advocated the aid to “suck the Soviets into a Vietnamese quagmire.”

When Moscow took the bait and sent troops that December to support the Afghan government against a growing rural insurgency, National Security Adviser Zbigniew Brzezinski gleefully wrote President Carter, “We now have the opportunity of giving to the USSR its Vietnam War.”

Call it blowback, or just an irony of history, but Afghanistan has turned instead into America’s second Vietnam War. The Soviets finally had the good sense to pull out after being bloodied for a decade. The Obama administration envisions staying there indefinitely. Under the Bilateral Security Agreement that President Obama got Kabul to sign in 2014, U.S. troops may remain in Afghanistan “until the end of 2024 and beyond.”

President Obama explicitly rejected any analogy to Vietnam in a speech nearly seven years ago. But like Vietnam, our ongoing conflict in Afghanistan has become a hopeless quagmire, marked by official lies, atrocities, pervasive corruption and poorly led government forces who survive in the field thanks mainly to U.S. bombing. Like Vietnam, Afghanistan represents a staggering waste of lives (more than 300,000 direct casualties through early 2015) and resources (more than two trillion dollars).

Even more than Vietnam, it is a conflict for which no one in Washington bothers to offer any strategic rationale. The best that President Obama could come up with in his July 6 statement on Afghanistan, was “I strongly believe that it is in our national security interest — especially after all the blood and treasure we’ve invested in Afghanistan over the years — that we give our Afghan partners the very best opportunity to succeed.”

The same logic is what keeps gamblers coming back to Sheldon Adelson’s casinos year after year to lose more money.

‘Precarious’ or Unwinnable?

In Vietnam, the United States couldn’t win with more than half a million troops. In Afghanistan, the United States couldn’t beat the Taliban with 100,000 troops. Obama doesn’t really think he can win with a mere 8,400 troops — especially with the Taliban making steady gains.

“The security situation remains precarious,” he admitted. “Even as they improve, Afghan security forces are still not as strong as they need to be. The Taliban remains a threat. They’ve gained ground in some cases.”

As in Vietnam, however, ambitious military officers and armchair civilian warriors claim confidently that victory requires just a modest degree of escalation. Sounding just like Vietnam-era hawks, Retired Gen. David Petraeus and Michael O’Hanlon of the Brookings — previously a cheerleader for invading Iraq — accused the administration of making “U.S. and coalition troops in Afghanistan operate with one hand tied behind their backs.” To win the war, they declared, “We should unleash our airpower in support of our Afghan partners.”

In Indochina, of course, all of our furious bombing, which unleashed three times the tonnage dropped in World War II, only hardened enemy resistance. Recent studies confirm that the bombing was ineffective and drove civilians into the arms of the Viet Cong, just as U.S. bombs, drones and night raids build support for the Taliban.

President Richard Nixon knew it at the time, though he insisted publicly that American bombing was “very, very effective.” As he wrote despairingly in a note to Henry Kissinger, his national security adviser, “We have had 10 years of total control of the air in Laos and V.Nam. The result = Zilch. There is something wrong with the strategy or the Air Force.”

Massive bombing could not make up for the unwillingness of South Vietnamese troops to risk their lives for corrupt leaders. As in Vietnam, which became known as the “dirty war,” Afghan officials have pocketed tens of billions of dollars earmarked for infrastructure and institution building. They also encourage rampant trafficking in opium and heroin, as do the Taliban.

The Taliban, however, use their profits to finance their insurgency, rather than siphoning them off to Dubai, where the families of leading Afghan officials maintain fat bank accounts and luxury villas.

Much of Afghanistan’s army consists of “ghost” soldiers and officers, who draw pay that enriches corrupt Army leaders. In some provinces, nearly half of all police are ghost employees as well.

Meanwhile, real soldiers are busy selling tens of thousands of U.S. weapons to the Taliban. Others fire their weapons at no one in particular so they can sell copper ammunition casings on the black market.

Pakistani Bases

Highly motivated Taliban forces are particularly tough to beat because they get refreshed and resupplied from bases in Pakistan, where their leaders reside. One of the key lessons of the Vietnam War was the near impossibility of defeating a determined insurgency that enjoys neighboring sanctuaries.

In Vietnam, at least, U.S. leaders pursued negotiations with the enemy to end the conflict. In Afghanistan, no one is sitting at the peace table, and the U.S. drone strike that killed Taliban leader Akhtar Mohammad Mansour in May was hardly a welcoming invitation from Washington.

Pakistan blames Afghanistan for the failure of the peace process to go anywhere. A spokeswoman for the Pakistani government cited the “absence of a national consensus in support of the reconciliation process,” as well as the “worsening security situation, corruption and other administrative problems.”

The Taliban and their unyielding allies are to blame as well. In June, Gulbuddin Hekmatyar, leader of one militant Islamist faction, demanded that the Kabul government send all foreign troops home and disband itself. Ironically, he was America’s (and Pakistan’s) primary ally during the war against the Soviet Union, despite (or because of) his reputation for pathological brutality and leadership of Afghanistan’s drug trade. So much for grateful allies.

So why doesn’t Obama just get out? That worked in Vietnam, which Washington today is courting as an ally. But like many CEOs today, Presidents think far more about the immediate future than about outcomes long after they leave office.

Again, Vietnam is instructive. President Lyndon Johnson heard plenty of warnings that the war was unwinnable, but remembered all too well how Republicans clobbered the Truman administration after the “fall” of China. As LBJ told Ambassador Henry Cabot Lodge in late 1963, “I am not going to lose Vietnam. I am not going to be the President who saw Southeast Asia go the way China went.”

Similarly, President Nixon — who built his career in Congress by playing the anti-communist card to the hilt — said he was not going to be “the first President of the United States to lose a war.”

President Obama knows full well that the Republican attack machine will go after him and other Democrats if he “loses” Afghanistan or Iraq, despite public ambivalence about both wars. So his calculated decision to keep fighting, at minimal cost and without any real hope of winning, makes political sense.

But his policy is also cowardly and immoral. President Obama — and his current secretary of state — should recall the testimony of former Navy Lt. John Kerry before the Senate Foreign Relations Committee in 1971.

Citing President Nixon’s vow not to be the first president to “lose a war,” Kerry asked, “How do you ask a man to be the last man to die in Vietnam? How do you ask a man to be the last man to die for a mistake?”