Prime Minister Benjamin Netanyahu on Monday said the border fence constructed along Israel’s border with Egypt is holding back a potential “flood” of illegal migrants from Africa, and charged they were worse than terrorists in the Sinai peninsula.

Speaking at an event celebrating the Negev region held in Dimona, the prime minister said that Israel has recently completed a fence along “more than 200 kilometers [120 miles] of the border with Sinai.”

Without the fence, “we would be faced with … severe attacks by Sinai terrorists, and something much worse, a flood of illegal migrants from Africa,” he said.

Get The Times of Israel's Daily Edition by email and never miss our top stories Free Sign Up

The comments come as Israel has embarked on a highly controversial campaign to deport thousands of African migrants in the country.

The 242 kilometer Egypt-Israel barrier, stretching from the Gaza Strip to the Israeli Red Sea resort of Eilat, was completed in 2014.

The Israeli government hoped it would tackle illegal migration, drug and weapons trafficking, and infiltration by terrorists. Illegal migration slowed to a trickle after it was completed. Terror attacks along the border, where Egypt has been fighting an Islamic State-led insurgency, reportedly with Israeli help, have also become rare.

US President Donald Trump has pointed to the wall as a model for what he hopes to accomplish along the Mexico border.

Netanyahu said that the only way in which Israel can ensure that it remains a Jewish, democratic state is to keep the migrants out.

“How could we assure a Jewish and democratic state with 50,000 and then 100,000 and 150,000 migrants a year. After a million, 1.5 million, one could close up shop,” Netanyahu said. “But we have not closed down. We built a fence and at the same time, with concern for security needs, we are making a major investment in infrastructures.”

The High Court recently halted Israel’s campaign to deport unmarried male migrants to third-party countries (widely reported to be Rwanda and Uganda), with jail time facing those who refuse to go. The Africans, nearly all from dictatorial Eritrea and war-torn Sudan, say they fled for their lives and face renewed danger if they return. Most arrived between 2006 and 2012.

Israel considers the vast majority of them to be job seekers and says it has no legal obligation to keep them. Israeli officials commonly refer to them as “infiltrators.”

Netanyahu also referred to the movie “The Ancestral Sin” (“Sallah, Po Ze Eretz Yisrael”), which used testimonials and previously sealed transcripts to depict discriminatory policies in the first two decades of the state against Jews from North Africa, particularly the Moroccans. Many of the recent immigrants from north Africa were housed in development towns in the Negev.

“In wake of the film ‘The Ancestral Sin,’ I instructed the Cabinet Secretary to check the issue with the World Zionist Organization,” he said. “The check showed that while the documents are indeed open, they are not accessible. Therefore I made a decision – they will be accessible to everyone in Israel, to everyone in the world, completely accessible. As we did with the Yemenite children affair, so we will do here.”

During his speech, Netanyahu was interrupted by a protester who was removed from the hall as the rest of the audience cheered on the prime minister with calls of “Bibi, Bibi.”