Updated

Israel's parliament this week approved a bill that would bar foreign activists who call for economic, cultural or academic boycotts of either Israel or the Jewish settlements in the West Bank -- a move that drew comparisons to President Trump's "extreme vetting."

If the law takes effect, it would set up a “blacklist” in border inspection computers, and anyone appearing on it would be stopped at Ben Gurion Airport.  It read: "No visa and residency permit of any type will be given to a person who is not an Israeli citizen or does not have a permit for permanent residency in the State of Israel if he, [or] the organization or entity for which he works, has knowingly issued a public call to impose a boycott on the State of Israel, as defined in the Preventing Harm to the State of Israel through Boycott Law, 5771-2011, or has committed to participate in such a boycott."

HAWAII SUES TO BLOCK TRUMP'S REVISED TRAVEL BAN

The legislation passed its third and final reading in the Knesset on Monday, with 46 lawmakers voting in favor and 28 opposing it.

Roy Folkman, who sponsored the bill, said the legislation was necessary in order to protect Israel’s "name and honor." Bezalel Smotrich, who helped spearhead the bill, said it showed that Israel "won’t turn the other cheek" and that it was a "natural" step for any country to take.

ISIS MURDERING COPTIC CHRISTIANS ON EGYPT'S SINAI PENINSULA OVER FAITH

While it has received a wide support in the right wing of the Israeli political arena, it drew strong criticism both within Israel and abroad.

Former justice and foreign minister Tzipi Livini called the law a "foolish move which harms Israel and strengthens the boycotters." She added that the law will not deter Boycott, Divestment and Sanctions (BDS) activists, since whoever wants to boycott Israel could continue to do so from outside of the country.

Omar Baraghouti, Palestinian human right activist, and the founder of the BDS movement, pledged to continue his fight against Israel by saying the law further delegitimizes Israel itself. "The non violent, inclusive, and clearly effective Boycott, Divestment and Sanctions movement is more than ever as an integral part of the rising global resistance to the far-right, in DC, Tel Aviv, and many cities in between. Isolated, we fail. United, we prevail."

Analysts have pointed out that although the bill appears more limited in scope than the proposed U.S. travel ban, it's not clear exactly what would constitute a "public call to impose a boycott."

The law would not have much of an impact on entry into Israel proper, but rather will mostly affect those trying to enter the West Bank. Because Israel controls every point of entry into areas under Palestinian control in the West Bank, Palestinians cannot leave or come back without a permit. With the passage of the law, they may no longer be allowed to have visitors.

An op-ed for the Israeli Newspaper Haaretz claimed the law, together with enforcement of the Anti-Boycott Law, which applies to Israeli citizens, would turn Israel into a model of McCarthyism.

The bill allows for exceptions to be made by the interior ministry, but it was unclear whether foreign politicians, academics and journalists would be turned away at the border.

The revised U.S. travel ban seeks to ease concerns about violating the due process rights of travelers from six predominantly Muslim nations. It temporarily bars new visas for citizens of Somalia, Iran, Syria, Sudan, Libya and Yemen and suspends the U.S. refugee program for 120 days. Iraq was dropped from the list of countries.

Trump officials said their goal was the same: to keep would-be terrorists out of the United States while the government reviews how refugees and visa applicants from certain parts of the world have been vetted.

The Associated Press contributed to this report.