Not in what was given to Moses, obviously, since man had already transgressed the commandment to not eat of the fruit of the tree. This was before man even knew good and evil. But I'd go even further and say even before man was created, God was and therefore his law was.
Let's say a man wanted to get a divorce. Was divorce lawful before the law came? No. Jesus was asked, “Is it lawful to divorce one’s wife for any cause?” 4 He answered, “Have you not read that he who made them from the beginning made them male and female, 5 and said, ‘For this reason a man shall leave his father and mother and be joined to his wife, and the two shall become one flesh’? 6 So they are no longer two but one flesh. What therefore God has joined together, let not man put asunder.” 7 They said to him, “Why then did Moses command one to give a certificate of divorce, and to put her away?” 8 He said to them, “For your hardness of heart Moses allowed you to divorce your wives, but from the beginning it was not so. 9 And I say to you: whoever divorces his wife, except for unchastity, and marries another, commits adultery.” Mt. 19:3-9
From the beginning he made them male and female suggesting divorce was against God's law from the beginning.
The Serpent was a murderer from the beginning John 8:44, suggesting murder was against God's law way before the law not to kill was given to Moses, and the Serpent or Satan was a liar and the father of all lies suggesting lying has always been against God's law even before the law to not lie was given to Moses.
Genesis 26:5
because
Abraham obeyed my voice and kept my charge, my commandments, my statutes, and my
laws.” This was before Moses was given the law.