By Frank Gardner
BBC Security Correspondent
The CIA believed the bomber had vital information on al-Qaeda
The revelation that the man who blew up himself, four CIA officers, three security guards and a Jordanian intelligence officer in Khost, Afghanistan, was a double agent is embarrassing for both the US and Jordan.
For Washington, it risks making a mockery of the CIA's attempts to track down and infiltrate the intimate circle of al-Qaeda's leadership.
One can only imagine how much false intelligence this al-Qaeda double agent had been feeding his handlers, before he killed them.
For Jordan, this is a clandestine relationship it would much prefer to have kept secret.
The idea that Jordanian intelligence officers are working hand-in-glove with the CIA will be deeply resented by many in Jordan.
Jordan's intelligence service, the General Intelligence Directorate (GID), has a fearsome reputation in the Arab world.
Rivalling Egypt's agency in its ability to uncover Islamist extremist networks, it has also been accused of human rights abuses and of colluding with the CIA's programme of extraordinary rendition of al-Qaeda suspects.
The GID failed to prevent al-Qaeda in Iraq's bombings of Jordanian hotels in Amman that killed 60 people in 2005.
But the following year it was patient, painstaking work by Jordanian human intelligence that led the Americans to their most wanted target in Iraq.
In June 2006, US special forces operating near the Iraqi town of Baquba were able to direct an airstrike that killed Abu Musab al-Zarqawi, the al-Qaeda leader in Iraq who had come close to triggering a sectarian war between Iraq's Shia and Sunni Muslims.
But now, following the disastrous blow to the CIA's intelligence gathering delivered by the Jordanian suicide bomber in Afghanistan on 30 December, US intelligence officials will likely be taking a close look at their intelligence-sharing with Jordan.
It appears that the bomber was, after all, an al-Qaeda "triple agent" who had supposedly been turned against extremism by Jordanian intelligence while in prison, recruited to spy on al-Qaeda, sent to the Afghan-Pakistan border region to try to get close to al-Qaeda's leadership, but who all the while had never abandoned his jihadi affiliations.
CIA DEATHS: 1965-2009
2009: Seven killed in suicide attack on their base in Afghanistan
2003: Two CIA contractors die in Shkin, Afghanistan; CIA officer killed during training exercise in Afghanistan
2001: Officer shot during prison uprising in Afghanistan
1993: Two CIA employees killed at the agency's Virginia headquarters
1989: Six CIA employees die when a plane carrying military equipment from DR Congo to Angola crashes
1985: CIA Beirut station chief killed after having been kidnapped and tortured
1983: Eight CIA employees killed in the US embassy bombing in Beirut
1965: Seven CIA employees die, most of them in Vietnam
Source: Washington Post
Named as Humam Khalil Abu-Mulal al-Balawi, the Jordanian physician apparently completely fooled his Jordanian handler, named as Capt Sharif Ali Bin Zaid.
He convinced both him and the CIA that he had urgent information to pass on, so a mini-summit of intelligence officers was convened on Forward Operating Base Chapman in Khost to hear what he had to say.
Since Jordanian intelligence had vouched for him, the bomber was never properly searched and, early in his bogus "briefing", he detonated the explosives on his body.
For the CIA, this is a blow on many levels.
It has lost some of its most valued officers with expertise at the sharp end, it will now have to go through the depressing exercise of re-evaluating everything their supposed mole had told them, on the basis that it is probably false.
It will have to assume that everything the assassin had been told and taught by his handlers - methods, codes, aliases - will all have been passed to al-Qaeda, who will take a keen interest in such information.
And above all, it shows that far from the growing complacency mouthed by Western government officials - that al-Qaeda was on the run after CIA drone strikes killed 15 senior al-Qaeda leaders and one Taliban leader in Pakistan's tribal belt since January 2008 - the fugitive organisation and its followers are, in fact, capable of striking back hard where it hurts.