The death of al Qaeda leader Ayman al-Zawahiri comes just days before the first anniversary of the US withdrawal from Afghanistan after 20 years.

The last days of what some have called world's longest war were chaotic and confused as US and Western troops pulled out.

Their departure left many questions about the future of Afghanistan, among them what the resurgence of the Taliban would mean for security in the West.

US President Joe Biden said the death of al-Zawahiri, one of the architects of the 9-11 attacks, followed months of planning and sent the message that "No matter how long it takes, no matter where you hide, if you are a threat to our people, the United States will find you and take you out".

Ayman al-Zawahiri helped co-ordinate the 11 September 2001 attacks in the US

But while the US President lauded the death as "justice...delivered" it raises other questions, not least how al-Zawahiri, as one of the world's most wanted terrorists with a $25m bounty on his head, was living in the open in the centre of the Afghan capital, Kabul.

Bill Roggio, a Senior Fellow at the Foundation for Defense of Democracies and Managing Editor of the Long War Journal, told RTÉ News that it is telling that al-Zawahiri didn’t die in any of the remote regions of Afghanistan and speaks of the senior al-Qaeda figure having had the confidence to be in Kabul.

That confidence, Mr Roggio added, tells us a lot about the relationship between the Taliban and Al-Qaeda, and while he understands the US administration presenting this as a win for the US, it in fact masks the fact that al-Qaeda feels perfectly able to operate openly once again in a Taliban-controlled Afghanistan.

Officials from both the Trump and Biden administrations had talked of how the Taliban would sever its ties with al-Qaeda, Mr Roggio said, but "none of this has happened, and instead...what we just witnessed is al-Qaeda operating inside the heart of Afghanistan".

It suggests a relationship between the two organisations as strong as two decades ago when the 9/11 attacks happened and when the US sent troops into Afghanistan to dismantle the operation which had brought such terror directly to the streets of New York.

Mr Roggio said it shows a Taliban emboldened by the events of the last 12 months which has seen it return to control.

The ties between the two groups are clearly strong and come, Mr Roggio said, from a shared sense of justification because of their perceived sacrifice in 20 plus years of fighting the West.

The questions asked by many when the US withdrew from Afghanistan was "had this all been for nothing?" and as the close links between the Taliban and al-Qaeda are shown in the case of al-Zawahiri that question will inevitably be asked again.

Al-Zawahiri's house
Smoke rises from a house following a US drone strike in Kabul

There are other questions too though, Mr Roggio believes, most notably the discussion around how the presence of al-Zawahiri was discovered.

He is adamant that authorities should have been far more circumspect in revealing their sources calling it "irresponsible" for US officials to reveal that they had on-the-ground intelligence.

It means, Roggio said, that the Taliban will now be actively hunting down any potential Western intelligence networks operating in the country, whether US personnel or former Afghan officials.

Instead, the focus should have been on providing protection to any intelligence on the ground and instead saying that the information leading to al-Zawahiri had been gathered from a distance, through electronics or tracking only.

Operational security should always take priority, Mr Roggio added, rather than the need to tout all details of the operation in public.

White House spokesman John Kirby said there was a small al Qaeda presence remaining in Afghanistan.

"We are still going to stay vigilant, we're still going to stay capable," Mr Kirby told MSNBC, adding that the United States had the capability to conduct a counter-terrorism strike from afar.

But Mr Roggio said the biggest security concern for the US right now in Afghanistan has got to be the enduring al-Qaeda-Taliban relationship. It gives al-Qaeda safe haven, he said, adding that even if al-Zawahiri's successor isn’t in Afghanistan yet, he will be very soon.