Yemen's success in ousting Al Qaeda from its southern strongholds this month has cemented President Abdrabuh Mansur Hadi's credibility, but analysts warn more challenges lie ahead for the new leader.
Although Al Qaeda has fled key towns, the conflict with them is not over as they have retreated to the safety of the mountains in vast and lawless regions of Hadramawt in the east, where they enjoy the protection of tribes.
Hadi's vow to destroy the terror network in Yemen was dealt a blow this week with the assassination of his southern commander, General Salem Ali Qoton, who spearheaded a month-long offensive against the jihadists.
Perceived as weak and ruling in the shadow of his veteran predecessor Ali Abdullah Saleh, Hadi "needed an opportunity to assert his power," said political analyst Fares Al Saqqaf.
The war against Al Qaeda "provided that opportunity" and allowed him to "make political and national gains," he said.
In office for nearly four months, Hadi has earned a reputation of being "serious about fighting Al Qaeda... the total opposite" of Saleh who was accused of letting the jihadists take control of swathes of territory.
The new president, a former military man from the southern province of Abyan where Al Qaeda set up base, personally oversaw the battles to oust the jihadists from areas they have held for more than a year.
One senior military official said the army offensive was "meticulously prepared" and followed a series of new appointments by Hadi in the army's top command posts, replacing Saleh loyalists.
He said "American logistical support and supervision by American experts on the ground, as well as the direct involvement of senior military commanders," were crucial to ensuring the new leadership's success against the militants.
The participation of the so-called Popular Resistance Committees, armed residents from the troubled towns and villages which Al Qaeda seized, was also a key factor in ousting the militants.
But Saqqaf warned that the "war is not over."
This "is not the end of the battle... but it is a strong blow to Al Qaeda," who are now clearly facing a "confrontation with the whole society," said Saqqaf pointing to the emergence of the residents fighting alongside the army.
Mohammed Bahada, a tribal chief and mediator between Al Qaeda and the army, said the militants were now likely to "change their strategy" by abandoning their goals of establishing an Islamist emirate in Yemen and pursuing instead "a war of attrition."
Al Qaeda's slain chief and founder Osama bin Laden reportedly criticised the network's Yemen offshoot for taking over urban centres in the south and east, arguing it made them easy targets for those that hunted them, specifically, the Americans.
According to Islamist expert Zeid al-Salami, Al Qaeda in Yemen is in the process of "revising their strategies... and taking stock of the mistakes" that led to their retreat from Abyan and Shabwa after the army offensive launched on May 12.
For Hadi, the sole candidate in February polls under a Gulf-brokered transition that forced Saleh to step down after 33 years, Al Qaeda is only one of the many challenges that threaten his two-year term in office.
Saleh continues to meddle in government affairs and many of his loyalists, including his son and nephew, still hold powerful positions in the military.
In a warning to Yemen's old guard, the UN Security Council unanimously passed a resolution last week threatening sanctions against anyone seen as undermining the fragile transition.
"The new president's removal of some of Saleh's family from key military and security posts is a sign of Hadi's increased authority," said Gulf analyst Neil Partrick, referring to his success in replacing the head of the presidential guard, Saleh's nephew, and the air force commander, Saleh's uncle.
"But there remain important Saleh family members and other military as well as tribal discontents able to undermine the new leadership's counterterrorism and anti-secessionist efforts," he said.
In the south, a resurgent separatist movement has gained momentum since the Arab Spring-style uprising against Saleh first erupted at the start of last year.
In the north, Zaidi rebels have consolidated their power in the face of a weakened central government and a divided military.
And in the capital Sanaa, Saleh's son Ahmad still reigns supreme over the country's best-equipped and well-trained forces, the Republican Guard.