Maltreatment of a parent through striking or cursing is placed on a par with murder and kidnapping and is punished in the same way—death.
The word curse simply means "to belittle," "to make light of," "to be contemptuous of."
In the book of Matthew, as Jesus was giving the Sermon on the Mount, He says:
You have heard that it was said by them of old time, You shall not kill, and whosoever shall kill shall be in danger of the judgment: But I say unto you, That whosoever is angry with his brother without a cause shall be in danger of the judgment: and whosoever shall say to his brother, Raca, shall be in danger of the council. (Matthew 5:21-22)
Raca means empty-headed; moron. It is a form of cursing, belittling, or speaking contemptuously of. The person who says this shall be in danger of the council.
But whosoever shall say, You fool, shall be in danger of hell fire. (Matthew 5:22)
Jesus is saying that He agrees with Exodus 21:15-17. For a child to speak contemptuously of or to consider his parents to be foolish puts him in danger of the death penalty. This is God's law, and here, Jesus Christ, our Savior, says that He agrees with it. He will be the God who judges. Cursing is placed on a par with murder, and there is a reason why: because it proceeds from this same attitude of heart. Thus, it is punishable by death.
The majesty and office of God is violated in the person of the parent because God regards the parent as His representative and as a type of Him. So, the fifth commandment is broken, and the wages of sin is death (Romans 6:23). It is that simple. In terms of the penalty, it is just as wrong to curse parents as it is to curse God.