The airstrikes that Emirati forces with Egyptian support conducted against militia positions in Libya in late August 2014 were sparked by an anti-Islamist military campaign in eastern Libya.  The campaign, led by retired General Khalifa Hifter and a breakaway faction of the Libyan military, has profoundly altered Egyptian-Libyan relations. But the roots of Egyptian meddling in Libya run deeper than Hifter’s current operation.

Among Libya’s many afflictions, none is more threatening to Egypt than the two states’ nearly 700-mile-long shared border. Border policing in Libya has always been weak and ill-defined—even under Muammar Qaddafi—but it has suffered a catastrophic decline following the dictator’s overthrow in 2011. Oversight of borders has devolved to a constellation of eastern militias that are only tenuously connected to the government and that, in many cases, are colluding in the very smuggling they are meant to combat. The border is now North Africa’s eastern thoroughfare for weapons, fighters, illegal migrants, and illicit goods flowing into the Levant, with profoundly destabilizing effects on the Sinai, Gaza, and Syria.

Egyptian government officials have repeatedly warned the weak Libyan government about the dangerous repercussions of its failure to rein in Libyan Islamist groups in the east. And to be sure, Libya’s governance vacuum and ongoing intermilitia fighting bear much of the blame for the deterioration of conditions on the border.

At least equal responsibility, however, must fall on the shoulders of the Egyptian government. Its long-standing neglect of the Western Desert has fueled the region’s cross-border smuggling economy, while the Egyptian military’s recent policy of co-opting tribal elites has left unaddressed the area’s underlying grievances. More importantly, Cairo and its Gulf supporters are taking an increasingly securitized approach to Libya that risks plunging both Egypt and Libya into deeper instability.

Toward a Proxy “War on Terror”?

General Khalifa Hifter, a former Qaddafi-era officer, marshaled a coalition of disaffected military units, tribes in eastern Libya, and federalist militias to attack Islamist forces in and around the cities of Benghazi and Derna in late May 2014. Since its start, the effort—Operation Dignity—has intensified border tensions and raised the specter of increased Egyptian political and military involvement in Libya in support of Hifter.

The general’s forces are fighting both moderate groups like Libya’s Muslim Brotherhood and militant ones like Ansar al-Sharia. By casting such a net, 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.

From the start, Hifter seemed to be borrowing the model of Egypt’s president, General Abdel Fattah el-Sisi. In practice, though, the Libyan and Egyptian contexts are vastly different from one another: Hifter’s “Libyan National Army” lacks the power, numbers, historical depth, and national support that Egypt’s army enjoys. But the septuagenarian general is nonetheless tapping into a deep current of Libyan frustration that looks to el-Sisi as an exemplar—and many of his supporters hail from eastern tribes with kin on the Egyptian side.

Hifter has claimed that he and el-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 for safe haven. And he predicted greater cooperation between Egypt and Libya toward the goal of ending “foreign intervention in Libya”—an oblique reference to both foreign fighters and meddling by Qatar and Turkey.

There are signs that Egypt has been deepening its alignment with Hifter, and many of Cairo’s actions against his Islamist enemies in Libya predate Operation Dignity. In late January 2014, for example, Egyptian authorities in Alexandria arrested Sha’ban Hadiya, the head of the Libya Revolutionaries’ Operations Room, a coalition of Islamist militias with branches in Tripoli and Benghazi that is currently fighting Hifter and his allies in Zintani militias. Only hours after the abduction, five Egyptian diplomats in Tripoli were kidnapped; local media reported that the abductors demanded that the Egyptian government free Hadiya, which it soon did.

After Hifter’s campaign began, reports surfaced of more direct Egyptian military involvement in Libya, although credible evidence is elusive. In early August, Egypt’s foreign minister, Sameh Shoukry, attempted to quash these rumors by asserting that Egypt has no intention of intervening militarily in Libya. An Egyptian security official in the border town of Salloum echoed this denial, stating that although the Egyptian military was building up forces on the border, it was not preparing for an incursion but rather increasing its effort to fend off smuggling. Predictably, Hifter himself denied any Egyptian military assistance in press interviews and in a late June interview with one of the authors—but he hinted at the possibility of “foreign support” in the near future. It is likely that el-Sisi and the Egyptian military are loath to intervene directly in Libya for fear of becoming embroiled in a quagmire that would sap their ability to deal with more pressing extremist threats on the opposite side of the country, in the Sinai.

That said, the Egyptian military—with the prodding of the United Arab Emirates and Saudi Arabia, which have underwritten el-Sisi’s regime—has been developing plans for providing assistance to Hifter and even taking direct action to break the ongoing Islamist gains in Benghazi and Tripoli. In the past few months, Egypt and the UAE reportedly deployed a special forces team to destroy an Islamist camp in eastern Libya. And now Emirati planes, with Egyptian support, destroyed several Islamist targets near Tripoli.

Ironically, Hifter’s anti-Islamist campaign in the east that was meant to reduce the threat to Egypt may have actually heightened it. It has compelled Islamist militias in Benghazi to combine their firepower into a single coalition, undermining the political space for more pragmatic Islamist factions. So, while Egypt wanted a reliable partner to fight Islamists in Libya, Hifter’s campaign has not impressed Egyptian leaders. Sameh Seif Elyazal, a 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.”

Contrary to some Western commentary, Egyptian support for Hifter or an increased Egyptian militarization of the Western Desert is not the solution to these problems. Engaging in a limited border incursion or sending military aid to Hifter’s forces would likely inflame an already tenuous environment on both sides of the border. It could embroil the Egyptian military in a complicated conflict that would sap its ability to deal with more pressing threats in the Sinai. Egyptian and Emirati support to anti-Islamist factions would further polarize Libya, which is already perilously divided, with warring militias and effectively two parliaments and two armies (one side supports Hifter and Egypt against the Brotherhood and one is in favor of Libya’s Islamists). And as Egypt and the UAE get involved on Hifter’s side, the foreign patron of the Islamists, Qatar, is likely to respond by expanding its support to Islamist militias—perhaps including advanced weaponry—resulting in a vicious cycle of violence in Tripoli and in the east.

A lasting solution to tensions has to tackle deeper-seated problems.

An Eastern Pandora’s Box of Weapons and Militants

Although the current focus is on the threat to Libya’s capital, the roots of Egyptian intervention and the current unrest stem from security concerns over the eastern border.

Multiple press reports and United Nations investigations have long singled out the Egyptian-Libyan border as a major entry point for weapons and militants destined for the Sinai, Gaza, and onward to Syria. Most of the traffic occurs by land; from Benghazi’s environs, the goods move east across the border to the Egyptian port of Marsa Matrouh and onward to the Sinai. Sea routes originate in Benghazi with weapons often transferred to smaller boats moving between the Gulf of Bardi in Libya and the Gulf of Salloum in Egypt. In Egypt, there are five main routes for smuggling weapons—two passing through Marsa Matrouh; two through Siwa, an oasis city; and one that moves goods via fishing boats from Marsa Matrouh to northern Sinai. The Egyptian town of Salloum is a major site of weapons seizures, but there is also significant activity to the north and south of the town and along the road connecting Marsa Matrouh and Salloum.

The Egyptian border guard maintains various ambush points to interdict smuggling, including one in the Farafra oasis in the Wadi al-Jadid Governorate targeting smugglers coming from Libya and Sudan. In the wake of the early August takeover of Libyan military bases in Benghazi by Islamist militias, including Ansar al-Sharia, Egyptian military forces reportedly increased their presence  along the border.

Automatic rifles, small caliber arms, and ammunition are the most common items seized by Egyptian authorities as smuggled weapons from Libya. But they have also confiscated heavier weaponry; in October 2012, for example, they captured 102 rocket-propelled grenades, 20 Grad rockets, three anti-aircraft guns, and nineteen improvised explosive devices in Matrouh Governorate. The frequency of seizures apparently increased in 2014, with Egyptian security sources reporting in early August that Egyptian forces are able to stop 70 percent of the smuggling as opposed to 25 percent in the past.

Efforts at cross-border cooperation between the Libyan and Egyptian states have been halting and largely confined to rhetoric. The two sides have exchanged regular delegations to discuss security cooperation generally. In July 2014, Libyan intelligence chief Salem Abdel Salam, Foreign Minister Mohamed Abdulaziz, and then army chief of staff Abdessalam Jadallah Al-Salihin met with their Egyptian counterparts in Cairo to discuss border security coordination and Libya’s security situation. More recently, the prime ministers of the two countries met in Washington, DC, for discussions that included the security situation. But the implementation of any agreements has been stymied by mutual political distrust and especially by the enfeebled state of the official border forces in Libya, which are underfunded, undermanned, and ill-equipped.

Many of the semiofficial militias that now control Libya’s side of the border (along with independent operators) receive government salaries but only nominally answer to competing ministries in the Libyan government. Nearly all have captured traditional smuggling networks and are reportedly colluding in transferring weapons and militants across the border.

Egyptian officials accuse the more Islamist of these groups, along with rejectionist factions like Ansar al-Sharia, of tolerating or actively abetting Egyptian militants. Cairo has long maintained that these militants have ties with groups it considers terrorists both inside and outside of Egypt—the Ansar Bayt al-Maqdis and the Muslim Brotherhood operating in Egypt, the Islamic State in Iraq and Syria, and Jabhat al-Nusra in Syria. The regime is especially concerned about the presence of a so-called Free Egyptian Army, with the aim of overthrowing the el-Sisi regime, gathering in camps on the border. Actual evidence of such a group remains hard to come by; even local tribes in Salloum who are sympathetic to the Egyptian government have denied its existence.

Egyptian Labor as a Source of Tension

The large number of Egyptian workers in Libya has been another recurring source of bilateral border tension, with kidnappings, visa restrictions, and tit-for-tat border closings by both sides becoming regular occurrences. Before the current fighting, the number of Egyptian workers—both temporary and permanent—was estimated to be between 300,000 and 1.5 million. Over 200,000 are believed to enter Libya illegally each year.

The majority of Egyptian labor and commercial traffic passes the Musaid-Salloum border crossing. Libya has repeatedly closed the border crossing and deported hundreds of Egyptians , often for “administrative or security reasons” but also for apparently arbitrary motives or pressure from local militias. In July 2013, for instance, Libyan militias in Musaid closed the border after Egyptian security forces arrested Muslim Brotherhood members attempting to flee to Libya following the Egyptian military’s ouster of Mohamed Morsi from Egypt’s presidency. Subsequent closures because of fighting in eastern Libya have caused the accumulation of hundreds of Egyptian transport trucks at the border, stirring the ire of residents of Salloum and Marsa Matrouh who depend on the commerce for revenue. Matrouhis across the Egyptian governorate have also protested the Libyan government’s decision to require them to obtain an entry visa to enter the country, while Libyans in turn have complained that Egyptian authorities denied them visas in retaliation.

Kidnappings of Egyptian migrant workers are also commonplace in Libya. For instance, in mid-October 2013 the leader of a Libyan militia abducted several dozen Egyptian truck drivers and held them hostage in the Libyan town of Ajdabiya, demanding that Egyptian authorities release his relatives who were detained in Egypt on charges of weapons smuggling. The Egyptian authorities responded by closing Egypt’s side of the Musaid-Salloum border crossing  for a few days.

In the wake of escalating intermilitia fighting in Tripoli and Benghazi, the plight of Egyptian workers has worsened. Twenty-six Egyptian workers died in a single rocket attack in Tripoli in late July.

And as the violence has intensified, so too has the exodus. Tunisia’s interior minister agreed to evacuate 13,000 Egyptians stranded at the Tunisian-Libyan border, while nearly 50,000 Egyptians have arrived at the Musaid-Salloum border crossing in the last month. The Egyptian Al-Ahram reported that the total number of Egyptians fleeing Libya could reach more than 400,000 workers. This influx could further damage Egypt’s already faltering economy: the Egyptian Chamber of Commerce anticipated in early August 2014 that Egypt’s 13 percent unemployment rate would increase because of these returning workers.

The Double-Edged Power of Tribes

The tribes of Libya’s eastern Barqa (Cyrenaica) region and Egypt’s Western Desert have long been connected through intermarriage and lineage. These cross-border bonds have proven crucial to facilitating the movement of contraband, weapons, and people across the border.

A key tribe whose influence straddles the border and affects affairs in both countries is the Awlad Ali. The Awlad Ali is a Bedouin community in Egypt’s Western Desert that numbers roughly 750,000, with fewer members in eastern Libya. Having reportedly fled from Libya to Egypt several hundred years ago, members of the Awlad Ali are bound by shared lineage to Libya’s powerful Ubaydat tribe and have played a prominent role in modern Libyan conflicts, such as Libya’s war with Chad and the 2011 revolution (in which they rebuffed an attempt by Qaddafi’s cousin to enlist their support for the dictator).

At home in Salloum and Marsa Matrouh, the Awlad Ali complain about systemic employment discrimination in favor of more recent arrivals from Cairo and the Delta region of Egypt. Those workers now constitute a significant proportion of the population of Marsa Matrouh. Disputes between local tribes and these more recent inhabitants over land ownership are also sources of tension.

Partly fueled by this alienation, the Awlad Ali and other tribes, particularly in Marsa Matrouh and Salloum, have increasingly tended toward Salafi ideology. The overwhelmingly quietist and somewhat apolitical Salafism has made inroads among the Awlad Ali, leading to the replacement of customary Bedouin law with Islamic law among other developments. Salafis have also helped bolster the Matrouhis’ rapprochement with the Egyptian military against the common foe of the Muslim Brotherhood.

For the Egyptian military, this realignment with the tribes has proven useful in soliciting help from the notables of the Awlad Ali and other local communities to combat weapons proliferation and cross-border trafficking. In mid-October 2013, el-Sisi traveled to Marsa Matrouh for the first of several visits, producing an accord in which Matrouhi tribal sheikhs agreed to surrender over 1,500 smuggled weapons  to the government by December of that year. In return, the government dropped several court cases against tribesmen and paid retribution to the tribal families of those killed in repression that followed the ouster of Mohamed Morsi. A local tribal leader declared the Egyptian army to be Matrouh’s “seventh tribe.”

Tribal power has gained an even greater degree of clout in cross-border affairs because Egypt and Libya did not follow through on plans to set up consulates in Marsa Matrouh and Tobruk, respectively. This was especially evident in the late 2013 negotiations over the release of the Egyptian truck drivers abducted in Libya. The impasse was ultimately resolved through the intervention of tribal notables on both sides of the border. In appreciation of these efforts, Egyptian military intelligence organized a ceremony in Marsa Matrouh to honor the Libyan “popular”—that is, tribal—leaders from Ajdabiya, Tobruk, and Musaid who played a role in freeing the abducted drivers.

Getting to the Roots

The Egyptian military’s policy of elite patronage among the Western Desert and Libyan tribes is reaping some short-term dividends. And its backing of Hifter through the Emirati strikes may have temporarily fortified the anti-Islamist forces.

Yet such a strategy is ultimately shortsighted. The airstrikes were not enough to stop Islamist-oriented Misratan forces from taking over the Tripoli airport, which had previously been controlled by Zintani militias aligned with Hifter. And no amount of Egyptian support—military or otherwise—will result in a complete diminishing of the Islamist threat to el-Sisi’s satisfaction.

In Egypt itself, the larger economic and structural problems afflicting the Western Desert that drive cross-border smuggling remain largely unaddressed; the Matrouhi tribes in particular continue to make demands for economic development, water projects, and a revision of land ownership laws. And perhaps most worrisome, Egyptian border control is becoming a function of President el-Sisi’s increasingly interventionist policy toward Libya.

A lasting solution that would help address the endemic insecurity of the Egyptian-Libyan border and lower bilateral tensions lies in mutual reconciliation and in political and economic reforms.

In Libya’s Barqa region and Egypt’s Western Desert, that means ending tribal and region-based discrimination (and favoritism), replacing patronage with real economic growth and infrastructure, and fully integrating these historically marginalized regions into each country’s political and economic life.

For Libya, a lasting solution also entails brokering a ceasefire and a national compact that replaces the Libyan militias currently on the frontier with a more regularized and centrally managed border force.

And Egypt and its Gulf backers will have to end a burgeoning trend of harmful meddling in Libya’s affairs under the guise of counterterrorism.

Unfortunately, in light of the recent airstrikes, the likelihood of any of that happening seems slim.

Ala’ Alrababa’h is a junior fellow at the Carnegie Endowment. David Bishop, formerly a junior fellow at Carnegie, is a researcher at the Eurasia Group. The authors are also grateful for the assistance of Mokhtar Awad, who was a Carnegie junior fellow and is currently a research associate at the Center for American Progress.