Question Restatement: Exegetically, is there anything in Biblical Texts that suggest what the "Law of Freedom" is, that is mentioned in James 1:25, and James 2:12.
Answer: The "Law of Liberty" is the "Law of Freedom"
The Greek word, "ἐλευθερίας" exists in both passages, and be translated as "Liberty"--or "Freedom":
James 1:25, GRK - ἰς νόμον τέλειον τὸν τῆς ἐλευθερίας
James 2:12, GRK - διὰ νόμου ἐλευθερίας
One justifiably begins with the hypothesis:
For such an important concept, this law must be referenced outside of Hebrews and James, and probably would be understood even by the Jewish community, as Christianity asserts the Mosaic Law was a "shadow" of the "Heavenly/Eternal Law".
But this concept is not clearly seen in any context, until the "Law of Liberty" is interpreted as the law about freedom, (i.e., "The Freedom Law", or "The Law of Freedom", (i.e. by applying Greek Attributive Genitive syntax)
By interpreting in this way, it is a "prima facie case" which law is being referred to, as the answer is quite literally all over the New Testament, and furthermore, was recognizable in Jewish Law, (Deut. 25), specifically:
Romans 7:2, NASB - For the married woman is bound by law to her husband while he is living; but if her husband dies, she is released from the law concerning the husband.
Romans 6:5-8, NASB - 5 For if we have become united with Him in the likeness of His death, certainly we shall also be in the likeness of His resurrection, 6 knowing this, that our old self was crucified with Him, in order that our body of sin might be done away with, so that we would no longer be slaves to sin; 7 for he who has died is freed from sin. 8 Now if we have died with Christ, we believe that we shall also live with Him,
Colossians 2:20-23, NASB - 20 If you have died with Christ to the elementary principles of the world, why, as if you were living in the world, do you submit yourself to decrees, such as, 21 “Do not handle, do not taste, do not touch!” 22 (which all refer to things destined to perish with use)—in accordance with the commandments and teachings of men? 23 These are matters which have, to be sure, the appearance of wisdom in self-made religion and self-abasement and severe treatment of the body, but are of no value against fleshly indulgence.
Galatians 4:21 - 5:1, NASB - 21 Tell me, you who want to be under law, do you not listen to the law? 22 For it is written that Abraham had two sons, one by the bondwoman and one by the free woman. ... It was for freedom that Christ set us free; therefore keep standing firm and do not be subject again to a yoke of slavery.
"Law" can Refer to a Single Commandment
It is not necessarily true that "Law" exclusively refers to the body of "Mosaic Laws", or "Eternal Laws", but can refer to one single law, for example:
"What is the Royal Law?"
James 2:8, NASB - If, however, you are fulfilling the royal [noble/kingly] law according to the Scripture, “You shall love your neighbor as yourself,” you are doing well.
In this context, James explicitly identifies "the Royal Law", from the "Whole Law", (verse 10).
Transgressing the Perfect Law of Liberty
James, again, juxtaposes the "Perfect Law of Liberty" with the former law, directing the Christians to fulfill the Law of Liberty "in the same manner" that the former law was observed: where a transgression in one place, would constitute a transgression of the entire law :
James 2:12-23, NASB - So [in this way] speak and so [in this way] act as those who are to be judged by the law of liberty. 13 For judgment will be merciless to one who has shown no mercy; mercy triumphs over judgment.
James, without ambiguouity, states that, under the Law of Liberty, a failure to show mercy constitutes a transgression of the entire Law--a very profound assertion.
The Greatest Commandment
In both contexts where the "Great Commandment of the Law" is addressed, the answer is "Qualified" in connection with "the Mosaic Law". This raises the question, "if the Mosaic Law was imperfect, or incomplete, then what is the Greatest Commandment--of all?"
Matt. 22:36, NASB - “Teacher, which is the great commandment in the Law?”
From a Christian point of view, the former "Great" commandment, to love--with all their hearts, minds, and might, (Lev. 19:18)--is superseded by the commandment to love--not with their ability, but to love as Jesus, with his heart, mind, and might*.
John 13:34, NASB - A new commandment I give to you, that you love one another, even as I have loved you, that you also love one another.
Notably, Paul stated that this commandment fulfilled the "whole law":
Galatians 5:14, NASB - For the whole Law is fulfilled in one word, in the statement, “You shall love your neighbor as yourself.”
So, What "Law" could this commandment fulfill?
Notably Paul spoke about two different laws:
Romans 8:2, NASB - For the law of the Spirit of life in Christ Jesus has set you free from the law of sin and of death.
So, the "Law of Freedom", would presumably fall within the "Law of the Spirit", if not one and the same thing. The "Royal Law", would fulfill the Law of the Spirit, as it certainly cannot fulfill the laws of Moses, Circumcision, the Priesthood, keeping Kosher, etc.
What the Law of Liberty IS NOT
Addressing this is a "Pragmatic" exercise--not necessarily "Semantic". Identifying Contrast and Juxtaposition, in exegetical study, helps rule out possibilities, with the intent of narrowing down the remaining possibilities to a certainty.
The Law of Liberty is Perfect, the Mosaic Law is Not, and Merely a Shadow:
James 1:25, NASB - But one who looks intently at the perfect law, the law of liberty, and abides by it, not having become a forgetful hearer but an effectual doer, this man will be blessed in what he does.
Hebrews 10:1, NASB - For the Law, since it has only a shadow of the good things to come and not the very form of things, can never, by the same sacrifices which they offer continually year by year, make perfect those who draw near.
The "Law of Liberty" is not the "Mosaic Law or Tradition"
Col. 2:14-17 - having canceled out the certificate of debt consisting of decrees against us, which was hostile to us; and He has taken it out of the way, having nailed it to the cross. 15 When He had disarmed the rulers and authorities, He made a public display of them, having triumphed over them through Him. Therefore no one is to act as your judge in regard to food or drink or in respect to a festival or a new moon or a Sabbath day— things which are a mere shadow of what is to come; but the substance belongs to Christ.
Col. 2:20-23, NASB - If you have died with Christ to the elementary principles of the world, why, as if you were living in the world, do you submit yourself to decrees, such as, 21 “Do not handle, do not taste, do not touch!” 22 (which all refer to things destined to perish with use)—in accordance with the commandments and teachings of men? 23 These are matters which have, to be sure, the appearance of wisdom in self-made religion and self-abasement and severe treatment of the body, but are of no value against fleshly indulgence.
Gal. 5:3-4, NASB - 3 And I testify again to every man who receives circumcision, that he is under obligation to keep the whole Law. 4 You have been severed from Christ, you who are seeking to be justified by law; you have fallen from grace.
Gal. 5:11, NASB - 7 You were running well; who hindered you from obeying the truth? 8 This persuasion did not come from Him who calls you. 9 A little leaven leavens the whole lump of dough. 10 I have confidence in you in the Lord that you will adopt no other view; but the one who is disturbing you will bear his judgment, whoever he is. 11 But I, brethren, if I still preach circumcision, why am I still persecuted? Then the stumbling block of the cross has been abolished.
And then, Paul, (or is it [Christopher Hitchens]?), states:
Gal. 5:12, NASB - I wish that those who are troubling you would even mutilate themselves.
Gal 5:14, NASB - For the whole Law is fulfilled in one word, in the statement, “You shall love your neighbor as yourself, (Lev. 19:18).” 15 But if you bite and devour one another, take care that you are not consumed by one another.
Resolving Matthew 5:17-19
Matthew 5:17-19, NASB - 17 “Do not think that I came to abolish the Law or the Prophets; I did not come to abolish but to fulfill. 18 For truly I say to you, until heaven and earth pass away, not the smallest letter or stroke shall pass from the Law until all is accomplished. 19 Whoever then annuls one of the least of these commandments, and teaches others to do the same, shall be called least in the kingdom of heaven; but whoever keeps and teaches them, he shall be called great in the kingdom of heaven.
Regardless if Jesus was commanding others not to annul the commandmenets, and commanded them not to teach others to do the same, this commandment was "Qualified"--in verse 18, "until all is accomplished". If this event occurs/occured, then this direction does not apply. Moreover, Jesus apparently exclused himself from this, as textually, it is argued that he did annul commandments, (the laws and traditions), and taught others this.
Eph. 2:14-17, NASB - 14 For He Himself is our peace, who made both groups into one and broke down the barrier of the dividing wall, 15 by abolishing in His flesh the enmity, which is the Law of commandments contained in ordinances [δόγμασιν/decrees], so that in Himself He might make the two into one new man, thus establishing peace, 16 and might reconcile them both in one body to God through the cross, by it having put to death the enmity. 17 And He came and preached peace to you who were far away, and peace to those who were near;
Col. 2:13-14, NASB - 13 When you were dead in your transgressions and the uncircumcision of your flesh, He made you alive together with Him, having forgiven us all our transgressions, 14 having canceled out the certificate of debt consisting of decrees [δόγμασιν/ordinances] against us, which was hostile to us; and He has taken it out of the way, having nailed it to the cross.
Col. 2:8, NASB - 8 See to it that no one takes you captive through philosophy and empty deception, according to the tradition of men, according to the elementary principles of the world, [h]rather than according to Christ.
Acts 15:28-31, NASB - 28 “For it seemed good to the Holy Spirit and to us to lay upon you no greater burden than these essentials: 29 that you abstain from things sacrificed to idols and from blood and from things strangled and from fornication; if you keep yourselves free from such things, you will do well. Farewell.” 30 So when they were sent away, they went down to Antioch; and having gathered the congregation together, they delivered the letter. 31 When they had read it, they rejoiced because of its encouragement.