Leviticus 25:47-53 King James Version (KJV)
47 And if a sojourner or stranger wax rich by thee, and thy brother that dwelleth by him wax poor, and sell himself unto the stranger or sojourner by thee, or to the stock of the stranger's family:
48 After that he is sold he may be redeemed again; one of his brethren may redeem him:
49 Either his uncle, or his uncle's son, may redeem him, or any that is nigh of kin unto him of his family may redeem him; or if he be able, he may redeem himself.
50 And he shall reckon with him that bought him from the year that he was sold to him unto the year of jubile: and the price of his sale shall be according unto the number of years, according to the time of an hired servant shall it be with him.
51 If there be yet many years behind, according unto them he shall give again the price of his redemption out of the money that he was bought for.
52 And if there remain but few years unto the year of jubile, then he shall count with him, and according unto his years shall he give him again the price of his redemption.
53 And as a yearly hired servant shall he be with him: and the other shall not rule with rigour over him in thy sight.