"But the stranger that dwelleth with you shall be unto you as one born among you, and thou shalt love him as thyself; for ye were strangers in the land of Egypt: I am the LORD your God." - Leviticus 19:34 KJV
For the Hebrew living in Israel before Christ was born compassion was legislated. Foreigners were to be treated with kindness. If a person wanted to live in Israel for a time to work or visit it was allowed. Israel didn't have closed borders. They also didn't have ghettos or prisons.
"Again, thou shalt say to the children of Israel, Whosoever he be of the children of Israel, or of the strangers that sojourn in Israel, that giveth any of his seed unto Molech; he shall surely be put to death: the people of the land shall stone him with stones." - Leviticus 20:2 KJV
Justice was carried out swiftly and a stranger didn't have to worship God but they also couldn't practice abominable things within the borders of Israel.
"And the LORD said to Moses and Aaron, 'This is the statute of the Passover: no foreigner shall eat of it... If a stranger shall sojourn with you and would keep the Passover to the LORD, let all his males be circumcised. Then he may come near and keep it; he shall be as a native of the land. But no uncircumcised person shall eat of it.' " - Exodus 12:43, 48 ESV
This part gets very interesting. The males needed to be circumcised in order to partake so it was a real commitment.
No foreigner was to eat of the Passover but a sojourner was a guest in Israel and they lived on a particular tribes land because all the land in Israel was owned by one of the 11 tribes (the Levites had no land).
"It shall be eaten in one house; you shall not take any of the flesh outside the house, and you shall not break any of its bones." - Exodus 12:46 ESV
Also the Passover was done in homes not restaurants, shops or inns so if you ate the Passover then you needed to do it in a person's house... sorry no leftovers could be brought home from it either.
The Passover was the recognition of the national salvation of Israel. They phrase 'keep the Passover' is often used but a better translation would be 'make the Passover'. There were no spectators at the dinner table. There were only participants.
Ghettos did form in Israel because Israel was disobedient to God's structure and it caused problems in Israel. Samaria was one of the ones we see in Christ's time.
"The Samaritan woman said to him, 'How is it that you, a Jew, ask for a drink from me, a woman of Samaria?' (For Jews have no dealings with Samaritans.)" - John 4:9 ESV
Jesus was the one speaking to this woman.
"Jesus answered her, 'If you knew the gift of God, and who it is that is saying to you, 'Give me a drink,' you would have asked him, and he would have given you living water.' " - John 4:10 ESV
"Jesus said to her, 'Everyone who drinks of this water will be thirsty again, but whoever drinks of the water that I will give him will never be thirsty again. The water that I will give him will become in him a spring of water welling up to eternal life.' " - John 4:13-14 ESV
Jesus was offering her a better gift than anything that could have been legislated under the law.
"The woman said to him, 'Sir, give me this water, so that I will not be thirsty or have to come here to draw water.' Jesus said to her, 'Go, call your husband, and come here.' " - John 4:15-16 ESV
This harkens back to the male circumcision necessary to partake of Hebrew hospitality legislated in the law but of course Jesus knew she had no husband. She was a sojourner and practicing that which was abominable on Hebrew soil. Adultery was punishable by death but Jesus didn't come for that purpose. He came to give life.
As I was doing this study I've been pondering McCarthyism and the error of it. The fear of Soviet infiltration lead to a search for anyone who practiced 'abominable' politics and it singled people out and blacklisted them. A dark chapter of American history. It was loveless and brutal.
How do we love people? We invite them to dinner and share the culture of faith.
"The cup of blessing that we bless, is it not a participation in the blood of Christ? The bread that we break, is it not a participation in the body of Christ? Because there is one bread, we who are many are one body, for we all partake of the one bread." - 1 Corinthians 10:16-17 ESV
A circumcision of the heart is needed to take communion. It isn't a ceremony it is an invitation into the family of God. A stranger can't celebrate the salvation Christ gives as a gift. They can do it outwardly by there are no spectators in this celebration... only participants.
I think we can learn a great deal from the way God instructed Israel to handle strangers. There is great honor and decency there.