In 2003, then-president Hosni Mubarak collapsed while delivering a televised address before the Egyptian parliament. The 75-year-old was revived shortly afterwards and managed to complete the speech to rapturous applause. Later, Egyptians would joke that, as doctors feared he may not survive, they asked Mubarak if he would like to offer some farewell words to the Egyptian people. "Why? Where are they going?" he replied.

Another joke has it that during a visit to the Giza Zoo, Mubarak was shown a tortoise thought to be one of the oldest animals on earth. When told the tortoise could live up to 250 years, Mubarak simply remarked, "We'll see."

As he approached the end of his 30 years in power, perhaps the one thing Mubarak aimed to impress upon the people of Egypt above all else was his inevitability. He had beaten the odds and survived longer than his three predecessors combined. He inherited a country of 45 million people and saw that population double over the 30 years of his rule. In that time, he managed to dismantle the social welfare programmes established under Gamal Abdel Nasser and reverse the relative political openness of Anwar el-Sadat's years.

Today, under the iron fist rule of Abdel Fattah el-Sisi, that Egypt is one of widespread poverty and mass repression. This week, as Egyptians ranging from liberal politician Mohamed ElBaradei to former Salafi jihadist Nagih Ibrahim took to their social media accounts to mourn the death of Mubarak, it is worth recalling that the recent bouts of nostalgia for that era appear oblivious to the fact that Egypt's current tragedy is Mubarak's lasting legacy.

Following el-Sadat's assassination in 1981, Mubarak announced his presidency by declaring an emergency law that suspended many basic rights. Initially assumed to be a temporary measure, the emergency law was never lifted and the resulting human rights abuses - arbitrary arrests, military trials, torture - became permanent fixtures of the Egyptian state.

Meanwhile, over time, the space for political contestation became increasingly limited to the ruling National Democratic Party (NDP). Little more than a rubber stamp, the NDP oversaw Mubarak's dismantling of the state's welfare obligations towards citizens, and ushered in the privatisation and crony capitalism that became the regime's most prominent feature in later years.

Known in Western capitals as a "moderate Arab leader", Mubarak became heavily reliant on the $2bn in annual aid that the United States dutifully paid to ensure Egypt would protect US regional interests, chiefly Israel's security amid its ongoing occupation and settlement of Palestinian land.

The 1991 US-led war to reverse Iraq's invasion and occupation of Kuwait proved to be a turning point for Mubarak. As a reward for the country's participation in the campaign, $20bn in outstanding national debts were wiped clean, allowing Egypt to aggressively solicit new loans and foreign investments.

Mubarak put much of that windfall towards further consolidating his rule, creating new patronage networks and enriching his own family. A 2014 report released by the Egyptian Initiative for Personal Rights showed that during the last 10 years of Mubarak's rule, poverty rates continued to rise despite the country's steady economic growth.

During the 2011 uprising, a widely-shared report suggested that the Mubarak family fortune could be as high as $70bn, offering some clues as to where much of that growth had gone.

During the same period, Mubarak's prime fixation shifted towards creating the conditions to allow his son Gamal to inherit the presidency upon his father's eventual death. Towards that end, the elder Mubarak sidelined elements within the military thought to be hostile to the hereditary project.

He granted increased powers to the civilian security apparatus and police forces, and cracked down harshly on civil society organisations, calling for political and socioeconomic reforms.

As the most deeply entrenched social movement, the Muslim Brotherhood emerged as Mubarak's chief adversary, taking advantage of the state's withdrawal of crucial services to establish a robust social welfare sector, and challenging the NDP's dominance in parliament.

Nevertheless, whenever the group was perceived to have threatened his grip on power, Mubarak was quick to dismantle its organisations, seize its assets, and imprison its leaders, making clever use of the global war on terror's logic to paint Islamist activists with the brush of violent extremism.

Union leaders, academics, intellectuals, and liberal and leftist activists were similarly repressed or co-opted, leaving little space for the emergence of genuine political alternatives.

In 2011, amid deteriorating socioeconomic conditions and increasing political repression, the Egyptian revolution broke out under the banner of dignity, freedom, and social justice. During the 18 days of the uprising, Mubarak repeatedly made clear that Egyptians did have a choice: it was him or chaos.

For the brief moments in which Mubarak appeared in court in 2011-13 dressed in a white prison uniform to answer for some of the crimes committed during his rule, it seemed the choice was a false one. But the judges overseeing his trial owed their positions to him, as did the military officials managing the country's political transition, and the oligarchs entrusted with keeping the economy afloat.

Although its head was overthrown, the regime, it seemed, was going nowhere. After his farcical acquittal in 2014, Mubarak would spend his remaining years in his private seaside estate. And so it was fitting that, upon his death by his family's side, Mubarak was given a state funeral and accorded all of the honours worthy of the regime of his successor.

Weeks after the 2013 coup that brought el-Sisi to power, security forces massacred 1,000 protesters in a single day with the same brutality with which in 2011, on Mubarak's orders, they killed hundreds at Tahrir Square and across the country. Tens of thousands of political prisoners continue to languish in the dungeons el-Sisi inherited from Mubarak. None of their victims were afforded the same dignity in life or in death.

Meanwhile, the regime has only intensified Mubarak era policies. Austerity measures have been pursued more ruthlessly, with food and fuel subsidies being stripped down. As a result, a third of Egyptians now live below the official poverty line; many more suffer under dismal socioeconomic conditions.

Draconian legislation heavily restricting NGO work, independent media, and the right to assemble have enshrined past abuses into law. A slew of constitutional amendments have strengthened el-Sisi's control over state institutions like the judiciary and could extend his presidency for decades to come.

This, inevitably, is Hosni Mubarak's legacy.

The views expressed in this article are the author's own and do not necessarily reflect Al Jazeera's editorial stance.