The remains of a burnt airplane at the Tripoli international airport in the Libyan capital damaged during fighting between anti-Islamist forces and Islamist militias on July 16. (Mahmud Turkia/AFP/Getty Images)

Recent reports of Egyptian military aircraft bombing Islamist militant positions in the eastern Libyan city of Benghazi have highlighted once more how the Mediterranean state has become a contested site of regional proxy wars. The projection of Middle Eastern rivalries onto Libya’s fractured landscape has a long pedigree, dating back to the 2011 revolution and perhaps even further, when Moammar Gaddafi’s propaganda apparatus portrayed the country as a plaything at the mercy of predatory imperialists. During the uprising, the United Arab Emirates and Qatar jostled for influence, with their respective special forces supporting disparate revolutionary factions with intelligence, training and arms. Initially, the choice of actors had less to do with ideological affinity and more with expediency, history and geography. Libyan expatriates residing in each country shaped the channeling of funds and weapons.

As the revolution wore on, these interventions had a profound effect on its trajectory and aftermath. The availability of outside patronage reduced incentives for factional cooperation and consensus-building on the ground. It sharpened preexisting fissures in the anti-Gaddafi opposition: Revolutionary factions competed for arms shipments, withheld foreign intelligence and targeting data from one another, and tried to outmaneuver one another in the revolution’s endgame – the liberation of Tripoli.

But the intra-regional tussling of the 2011 revolution pales in comparison to the intensity of today’s proxy war. Back then, the factions and their foreign backers were at least united in the common goal of toppling a universally despised tyrant. Today, the outside powers are engaged in a struggle far more divisive and consequential: a war of narratives.

A dangerous scenario looms ahead. Backed by Egypt and the UAE, the Libyan government is extending the narrative of its counter-terrorism struggle against jihadists in Benghazi to include what is effectively a multi-sided civil war in Tripoli and the western mountains – of which Islamists are only one player. It is a multifaceted struggle that is only partially understood, and for which the literature on proxy interventions does not fully account.

Political scientist Karl Deutsch forwarded an early definition of proxy wars as: “an international conflict between two foreign powers, fought out on the soil of a third country; disguised as a conflict over an internal issue of that country; and using some of that country’s manpower, resources and territory as a means for achieving preponderantly foreign goals and foreign strategies.” Recently, Andrew Mumford criticized this definition for being “too state-centric,” arguing instead that proxy wars are “conflicts in which a third party intervenes indirectly in order to influence the strategic outcome in favor of its preferred faction.”

In the Libya case, however, neither definition is satisfying because they leave out the crucial element of narrative.

The inflection point in Libya’s post-revolutionary narrative arguably came from outside the country, in the rise of now-President Abdel Fattah al-Sisi in neighboring Cairo. Without meaning to intervene, at least initially, the Egyptian strongman cast a long and ultimately polarizing shadow over Libya’s unsettled politics. In both word and deed, he was an exemplar to embattled and desperate segments of the Libyan population: The ex-regime officials, key eastern tribes, federalists and younger liberals, who began idolizing the military uniform, the proverbial “man on horseback,” as the salvation for the country’s worsening violence and, less nobly, a way to exclude their ideological opponents from power.

To be sure, the maximalist positions and immaturity of Islamist politicians in Libya’s dysfunctional parliament, and especially their channeling of funds to revolutionary militias and, in some cases, U.S.-designated terrorist groups like Ansar al-Sharia at the expense of the regular army and police, bear much of the blame for this desperation. But the narrative shift imparted by the “Sisi Effect” meant that previous debates in Libya about dialogue, disarmament and reintegration were replaced with the more toxic and unyielding discourse of a “war on terror.” And perhaps most importantly, the rise of Sisi created a new part in Libya’s narrative script, waiting for an actor to play it.

That actor, as is well known, is Gen. Khalifa Hifter, the septuagenarian commander of Libya’s disastrous intervention in Chad, defector, and 20-year resident of northern Virginia who returned in 2011 in an unsuccessful bid for military leadership. In May 2014, Hifter announced the launch of Operation Dignity, a coalition of eastern tribal militias, federalists and disaffected military units, which began shelling the positions of Ansar al-Sharia and Islamist militias in and around Benghazi. In both tone and action, Hifter tried to align himself early on with Egypt’s military regime, which has been fighting its own Islamists in Egypt. Hifter also directly called on Egypt to use “all necessary military actions inside Libya” to secure its borders. At the same time, he declared Operation Dignity to be aimed at preventing Islamists from threatening “our neighbors in Algeria and Egypt,” further emphasizing the regional aspect of his campaign. There were echoes of neo-Nasserism in his rhetoric. He claimed that he and Sisi agree that fighting terrorism is a way to “emphasize our Arab identity.” He pledged that he would not permit any anti-Egyptian militants to exploit Libya’s eastern border as a safe haven.

Egypt has very real security concerns about the porous Egyptian-Libyan border. Multiple media reports and U.N. investigations have long singled out the border as a major entry point for weapons and militants destined for the Sinai, Gaza and onward to Syria. Gunmen reportedly based in Libya killed 21 Egyptian border guards in July. But as I recently argued, Egypt’s motives in Libya follow a timeworn tactic of deflecting internal problems onto an external source. Much of Egypt’s border insecurities lie on its side of the frontier: Its governance deficiencies in the Western Desert – specifically, its policies of co-opting local tribal and religious elites without addressing deeper structural problems related to land ownership, infrastructure and employment.

Ironically, Hifter’s anti-Islamist campaign in the east, while originally intended to reduce the threat to Egypt, may have actually heightened it. The campaign has compelled Islamist militias in Benghazi to combine their firepower into a single coalition, undermining the political space for the more pragmatic Islamist factions. It sparked a counter-mobilization in Tripoli, the so-called Operation Dawn, a coalition of militias from Misrata, Amazigh factions, western towns and Islamists. This coalition attacked Tripoli International Airport, which was controlled by Zintani militias allied with Hifter. Having seized the airport, certain Dawn factions have taken their campaign into the western Nafusa mountains, even reportedly going so far as to conduct airstrikes of their own on Zintan.

Egypt wanted a reliable partner to fight Islamists in Libya, but Egyptian leaders are not impressed with Hifter’s campaign. Egypt has found its local proxies rife with competing agendas and deficiencies in competence. There are now increasing signs that Cairo is distancing itself from Hifter. One retired Egyptian general complained that while Hifter “is doing his best … he has not proved that he can really put the Islamist radicals in their place.”

More recently, Sisi has invoked the anti-Islamic State clause to justify Egyptian support to Libya’s government. The Egyptian president’s recent offer of military assistance to Operation Dignity was explicitly framed as part of a broader anti-Islamic State fight. Leaked documents in mid-September purportedly showed that this was not merely an offer but rather a formalized agreement of military cooperation between the two states.The Egyptian media has bolstered the narrative as well. Cairo is home to several pro-Dignity media outlets, including the Libya Awalan TV station owned by Hasan Tatanaki, a Libyan business magnate with a virulently anti-Islamist outlook, and a more recent addition with the giveaway name of Karama (Dignity) TV.

A recent emphasis in the Egyptian media has been on the burgeoning presence of the Islamic State on Egypt’s border, particularly after the Islamic Youth Shura Council, a jihadist faction in the Libyan port city of Darna, announced that Darna was a territorial dependency of the Islamic State. This is an alarming development but one that should be tempered by the questions that still remain about what this means operationally for the training and facilitation of fighters, given the geographic space that separates the two and that the Islamic State has yet to respond to the Darna group’s unilateral declaration. Moreover, the jihadi field in eastern Libya, particularly in Darna, has been rife with fissures and debates about tactics and also fealty to the Islamic State. Most significantly, the Islamic Youth Shura Council has been engaged in a running battle for influence in Darna with the Abu Salim Martyrs Brigade, which rejected its claim. Recently, three members of the brigade fled Darna after the Shura Council sentenced them to death for not pledging allegiance to Abu Bakr al-Baghdadi. The Shura Council’s recent appeal to the supra-nationalism of the Islamic State smacks of a bid to outmaneuver its local rival for popular support. Ansar al-Sharia, in both Darna and Benghazi, has yet to come down one way or another on support for the Islamic State.

For its part, the UAE has been both a partner and an instigator of Egyptian intervention. The UAE’s activism is informed by a broader concern about the rise of the Muslim Brotherhood and the growing influence of its rival Qatar in Libya’s post-Gaddafi order. Yet it too has framed its involvement in Libya as part of a broader fight against al-Qaeda and the Islamic State. Emirati military links inside Libya have a long pedigree, dating back to the 2011 revolution, when its special forces channeled support to the Zintani militia brigades that are currently allied with Hifter against the Misratan, Amazigh (Berber), Islamist and Nafusa-based armed groups comprising the Dawn coalition. The UAE has long hosted politicians hostile to the Brotherhood and allied with Operation Dignity, including Mahmoud Jabril, chairman of the National Forces Alliance (NFA) and Aref Ali Nayed, currently the Libyan ambassador in Abu Dhabi. In the wake of Hifter’s campaign, the UAE intensified its military involvement. Operation Dignity’s stalling in Benghazi and the apparent advances of Misratan armed groups in the battle for Tripoli’s airport prompted the Emiratis to respond with a series of nighttime airstrikes on the Misratan positions. Emirati special forces also purportedly launched cross-border raids to demolish a jihadist training camp outside of Darna.

Qatar has reportedly stepped up its assistance to the Dawn faction, allegedly acting in coordination with Turkey and Sudan. As a forthcoming edited volume on the history of the Libyan Revolution makes clear, it was Qatar’s growing support of the network of Islamist revolutionaries clustered around the Doha-based cleric Ali Sallabi that pushed Jibril and Nayed to solicit greater backing from the UAE, France and the United States. Qatari aid also induced splits in the opposition as Ismail Sallabi – Ali’s more radical younger brother and the commander of a Benghazi based militia – tussled with Hifter over weapons shipments. The two are now bitter foes in the ongoing fighting in Benghazi. In the Nafusa mountains, there were similar fissures: The UAE set up an operations room and channeled support to Zintan, while Qatar favored nearby Nalut because of the presence of fighters from the Libyan Islamic Fighting Group (LIFG). Contrary to common assumptions, Doha did not back the former muqatilin (fighters) from the LIFG because of an Islamist project but because it assessed them to be among the more cohesive and capable of the revolutionary factions. Qatar also opened up independent channels of support to Misratan notables and revolutionary leaders, many of whom are now key in the anti-Hifter Dawn coalition.

Operation Dignity attacks in Tripoli have been accompanied by allegations of Qatari support to Tripoli-based Misrata and Islamist factions, using Turkey and Sudan as intermediaries. With Tripoli’s airport non-operational, Qatari cash and weapons shipments are believed to be funneled through the Matiga airport, on the eastern flank of Tripoli, which is under the control of Islamist militias. The alleged support from Qatar has produced an escalatory response from Operation Dignity forces, with dire consequences for civilians caught in the crossfire. As early as June, Hifter asked Turkish and Qatari citizens to leave eastern Libya within 48 hours, claiming “those with Qatari and Turkish passports are intelligence agents and consultants supporting the Islamist forces.”

In many respects, the war of narratives underway in Libya is a mirror of the polarization that is underway in the Gulf itself and in the broader Arab world. In tandem with Saudi Arabia, the UAE has erected what amounts to a legal, political and military cordon sanitaire against Islamist political mobilization, specifically from the Brotherhood. What is remarkable about Gulf intervention is the brazenness of it and that the opposing Gulf states – UAE and Qatar – are both members of the U.S.-led anti-Islamic State coalition. Together with Egypt, the UAE, Qatar and Turkey were among the signatories of a recent 13-country statement pledging non-interference in Libya’s internal affairs. But such oaths ring hollow in the face of recent airstrikes and the under-the-table shipments of funds and weapons.

More recently, the dragnet against activists in the UAE has extended to Libyan opponents of Operation Dignity; at least 30 Libyan nationals have been arrested in the UAE, including an Al Jazeera employee. At least two of those arrested were Libyan businessmen who had been residing in the UAE for more than 10 years, and their links to Libyan political actors, let alone radical groups, have yet to be corroborated. Human rights organizations have expressed outrage at the extrajudicial nature of the detentions – conducted without warrants – and warned of the potential for the prisoners to be tortured like Egyptians who were arrested a year before. As the arrested Libyans remained missing as of early October, Human Rights Watch issued a call for the UAE to reveal the locations of the “disappeared” Libyans.

Meanwhile, Thinni recently vowed to “liberate” Tripoli, and the Libyan parliament in Tobruk voted to bring Hifter and his forces under the purview of the government. Having realized the limits of airstrikes in dislodging entrenched opponents in an urban setting, the Dignity forces are now calling for tribal and societal mobilization in both Benghazi and Tripoli. U.S. commentators have argued that Washington should lend greater military support to the Dignity forces, throwing its lot behind the UAE and Egypt in their intervention. But such a policy would invariably throw the country deeper into chaos and intensify the very radicalism that the United States is keen to combat.

For now, the United States is steering a middle ground. In repeated statements, U.S. officials – along with the United Nations and Western diplomats – have emphasized political reconciliation  rather than military force as the solution for Libya’s conflict. But future U.S. engagement is fraught with pitfalls. Plans for U.S. military assistance to Libya are guided by a broader counter-terrorism strategy, which relies heavily on training and mentoring local special operations forces. Undertaking such an effort now, amid Libya’s fractured politics, risks falling into the narrative trap being set by one side in the struggle, with the support of its outside patrons. Injecting a new military force into an already divided security sector will likely perpetuate the conflict without decisively resolving it. The United States should hold off on training the Libyan military until a national reconciliation is enacted and a unified government is in place. It should work toward creating security forces that are representative of all of Libya’s tribes and regions, and it should ensure that these forces are placed under the close control of an inclusive, civilian and elected government with broad national representation.

Frederic Wehrey is a senior associate in the Middle East Program at the Carnegie Endowment for International Peace and a frequent visitor to Libya.