The story of how our intelligence services and special forces tracked down and killed Osama bin Laden is one of extraordinary dedication and in the end, a risky riverboat gamble that almost blew up into tragedy. For despite all the hard work of the intelligence professionals who were pursuing the leads that eventually led to bin Laden’s hideout, when Navy SEALs burst through the door of the mansion they were “not certain” that the terrorist was even there.

What was certain was that the painstaking process that led to a “high degree of certainty” that Osama bin Laden was hiding in that compound in Abbottabad spanned 4 years, two administrations, and dozens of CIA analysts following up hundreds of leads. They eventually tracked one lone man across the entire expanse of Pakistan, zeroed in on his location, and developed the “actionable intelligence” to give policy makers the choice to attack or stand pat.

All of this with no thanks to the Pakistanis — who must now be viewed with even more suspicion about their cooperation with America’s enemies. Osama bin Laden was not hiding in a cave somewhere in the Northwest Frontier Province as many believed. Instead, he was ensconced in relative comfort in an upscale neighborhood in a city — Abbottabad — where an entire regiment of the Pakistani army was based and the country’s military academy was headquartered. The area in which the terrorist was hiding out had many retired Pakistani army officers.

The house was built in 2005 and was designed to house someone of great importance, intelligence analysts believe. One report from Gulf News says that the house was actually a former safehouse for the Pakistani intelligence service, the ISI. Given the location of the structure, that is not beyond the realm of possibilities.

The US government did not trust the ISI, as Wikileaks documents show. One document says that “In Pakistan, Osama Bin Laden wasn’t an invisible man, and many knew his whereabouts in North Waziristan,” but whenever security forces approached, the ISI tipped bin Laden off.

Deputy National Security Adviser John Brennan flatly told reporters that it was “inconceivable” that bin Laden did not have the support of at least some elements of the Pakistani government. This suspicion led the US to keep the attack a secret from President Zardari and his government until the SEALs were safely out of the country.

The story of how Osama bin Laden was killed begins in the secret prisons abroad and the Guantanamo Bay detention center where some detainees told interrogators of several couriers used by al-Qaeda to avoid electronic surveillance. One such courier piqued the interest of the CIA: a protege of Khalid Sheikh Mohammed and a trusted assistant of al-Qaeda number 3 Abu Faraj al-Libbi (captured in 2005). Other detainees mentioned that bin Laden himself trusted this particular courier. However, all the CIA had on the target was his al-Qaeda nickname.

KSM, who had, by this time, been cooperating with his jailers, was confronted with the name of the courier and denied knowing him. The denial spurred the analysts to action and they began a worldwide search for the full name of the courier. Later that year, the CIA learned his full name, it is thought, through interrogations at one or more of the secret prisons the CIA maintained at the time.

It took two more years to focus on where the courier actually lived in Pakistan. No details have emerged as to how this part of the investigation was carried out, but it would imply both human assets and technical surveillance was involved.

Then, in 2009, intelligence began to zero in on where the courier and his brother operated. The fact that the courier was taking extraordinary precautions, strictly adhering to operational security, gave analysts hope that they were indeed on the right track.

The break came in August 2010, when the courier was spotted on an Islamabad street. It should be noted that there was nothing “lucky” about this break. The lead was the product of long hours of painstaking examination of the tiniest slivers of intelligence, agonizing over whether the nuggets of information were valuable, making intelligent judgments about where the information might fit into the overall picture they were developing, and finally being rewarded with a breakthrough.

Luck had nothing to do with it.

The CIA had a target but now had to figure out how to proceed. It was not as simple as trailing him back to the compound, given the chance that even a hint that the courier was being watched would have sent bin Laden scurrying for cover. Rather than take that chance, the CIA set up a more “elaborate” surveillance regime, probably involving small, nearly silent drones and real-time satellite coverage.

Eventually, the courier led them to the compound in a quiet neighborhood of Abbotobad. From the start, the CIA knew it was on to something. The mansion was 8 times larger than any other house in the area, featured a 16 foot wall topped with barbed surrounding the property, and appeared to be heavily guarded.

According to theNew York Times, the CIA had concluded by September, 2010 there was a “strong possibility” that Osama bin Laden’s hideout had been found. At that point, it became a matter of using all the tools of the trade to figure out how many people were living in the house, the layout of the compound and the house, and pursing confirmation of the presence of bin Laden.

It was discovered that there were three families living in the mansion: the courier, his brother, and a family on the third floor that fit the profile of who Osama bin Laden had taken into hiding with him. But the intelligence still wasn’t “actionable” because there were so many uncertainties involved.

Despite the most sophisticated technical means on earth, in the end, it came down largely to brute brainpower and human judgment. Over the next few months, analysts used multiple methods to analyze every angle, and what kept coming out of their gaming the scenarios was that it was a “high probability” that Osama bin Laden was located in the compound.

At this point — early March — SEAL Team 6 was activated and tasked with carrying out the operation. These warriors are probably the most elite unit in the US military. Officially called the Naval Special Warfare Development Group, but known as just DevGru, they got right to work constructing a mock-up of the compound and rehearsing the raid several times.

After 5 top level meetings of the National Security Council, President Obama gave a go-ahead for the mission on Friday night. On early Sunday morning, the SEALs took off from a base in Afghanistan and proceeded to the compound. CNN reports there were about 2 dozen commandos flying in 4 helicopters — quite possibly MH47E special operations aircraft, flown by another elite unit, “The Night Stalkers.”

The SEALs originally planned to rappel down to the ground but were forced to change plans when fire from the roof of the mansion made a “soft” crash landing necessary. The operation proceeded flawlessly with the SEALs making their way through the first floor, killing both couriers and one of Osama’s sons. Bin Laden was on the third floor. He was shot once in the head and then in the chest after he had gone down. The president and his advisers were able to watch the attack in real time in the situation room that Brennan characterized as “probably one of the most anxiety filled periods of time I think in the lives of the people who were assembled here yesterday.”

Perhaps not as big a coup as killing the terrorist, but the capture of several computer hard drives as well as a treasure trove of documents will no doubt contribute a great deal to our intelligence about al-Qaeda and perhaps their future operation plans. The SEALs are well trained to go through a house that size and pull out every possible relevant piece of intelligence and do it quickly. From start to finish, the operation took only 40 minutes.

We were able to confirm that the body was Osama bin Laden’s through a combination of facial recognition software and DNA analysis using samples from several of bin Laden’s close relatives. Also, the SEALs reported that bin Laden’s wife identified him. She was slightly wounded and along with her children, escaped from the house.

Near tragedy was averted when one of the copters suffered mechanical failure or was damaged in the attack and couldn’t take off. With Pakistan’s air defenses alerted and jets scrambled to intercept them, the SEALs calmly switched to “Plan B,” scooping up the occupants of the damaged aircraft and then destroying the copter to prevent its extraordinary technology from falling into the wrong hands. Once the SEALs were clear of Pakistan, President Zardari was informed of the assault.

In all, the feat was an incredible display of American military prowess, adding much moral clarity to an increasingly jaded, confused political climate. Every member involved in the operation — spanning administrations past and present — have certainly earned their bragging rights.