Whatever the law teaches, commands or promises it always has Christ as its object. The Mosaic Law never made anyone perfect - but Christ in his passive obedience (unto death) fulfilled the ceremonial law and in his active obedience fulfilled the moral law in his life. He also fulfilled the prophecies, so all the law and the prophets point to Him. Christ is the end of the law in that He fulfilled or satisfied the demands of the law completely. So Christ Himself became the righteousness of God on behalf of all who are joined to Him. Therein is where our hope for righteousness lies.