President Barack Obama signed a strategic partnership agreement with Afghanistan and barely hours later Taliban mounted an audacious attack in Kabul that left 11, including five terrorists, dead.
"This is hard," a senior administration official said in a background briefing on the 10-year agreement with President Hamid Karzai signed by Obama during a visit to Kabul under cover of darkness on the first anniversary of the US raid that killed Osama bin Laden in neighbouring Pakistan.
"Pakistan is not going to have completely changed the strategic orientation, which means that they are not going to be comfortable with a Kabul government that is too closely aligned with India," he said when asked if the accord on the role of US forces beyond the end of the war in 2014 was going to work.
This "means that they're going to be nervous about the Northern Alliance, which means that they're going to be continuing to seek hedges," the official said. "So if you combine all those factors, this is still going to be tough."
However, Obama himself sounded confident as he told Americans in a high-profile television address from the war-torn nation that he has wound down two unpopular wars since taking office three years ago and the defeat of Al Qaeda is "within reach".
"My fellow Americans, we have travelled through more than a decade under the dark cloud of war. Yet here, in the pre-dawn darkness of Afghanistan, we can see the light of a new day on the horizon,"
Shortly after arriving, about midnight local time, Obama and Karzai inked a pact to designate Afghanistan a major non-NATO ally. The agreement says the US will provide aid, advisers and support after NATO combat troops leave in 2014.
"The goal that I set - to defeat Al Qaeda, and deny it a chance to rebuild - is within reach," Obama said, adding that "there will be difficult days ahead. The enormous sacrifices of our men and women are not over."
There are around 130,000 forces in Afghanistan, including around 90,000 US forces and 40,000 troops from other nations. Those forces are scheduled to end combat operations after 2014, about thirteen years after the war began.
A new Pentagon report noted that US-led coalition forces have weakened the Taliban in Afghanistan, but terrorist safe havens in Pakistan and endemic corruption still pose tough challenges.
"The Taliban-led insurgency's safe haven in Pakistan, as well as the limited capacity of the Afghan Government, remain the biggest risks to the process of turning security gains into a durable and sustainable Afghanistan," the latest semi-annual Pentagon report to the Congress Tuesday said.
Insurgents "still operate with impunity from sanctuaries in Pakistan", the report said.
"Challenges remain," a senior defence official told reporters in a background briefing on the report. "The most important of those challenges, of course, remains the sanctuaries in Pakistan and the ability of the Taliban to refit, regroup and rearm there."
The Taliban and the Haqqani network use areas in Pakistan's federally administered tribal areas to attack Afghan and NATO troops.
"It's Pakistan's duty as a responsible international country to control all violence that emanates from its borders into other areas," the official said. "And we continue to urge them to do so."