Under the Law of Moses, God commanded the Israelites to obey the court rulings and respect the officials.
10 You shall do according to the sentence they pronounce upon you in that place the Lord your God chooses for His name to be called upon there. Thus you shall be very careful to do according to all they order you. 11 According to the law and the judgment in which they instruct you, you shall do; you shall not turn aside to the right hand or to the left from the sentence they pronounce upon you. 12 Now the man who acts arrogantly and will not obey the priest or the judge who may be there in those days, and who stands to minister in the name of the Lord your God, that man shall die. So you shall put away the evil from Israel. 13 Then all the people shall hear and fear, and no longer act impiously.Deuteronomy 17:10-13 OSB
The penalty for disobeying a judgment or disrespecting a court official was death.