Allah, the Blessed and Exalted, says: "And We prescribed for them therein (in the Torah): a life for a life, an eye for an eye, a nose for a nose, an ear for an ear, and a tooth for a tooth, and for wounds (also) retaliation." [Surah al-Ma'idah: 45]
Imam al-Shafi'i (may Allah have mercy on him) said: "I know of no disagreement that the retaliation mentioned in this verse, as Allah Almighty has stated, was the basis on which judgement was given among the people of the Torah." And he also mentioned its meaning.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الجنايات / Q16093