Karṇa was without weapon, and he fell down from the chariot. Karṇa, after falling down from the chariot, and he was trying to raise the wheel of the chariot from the mud, so Kṛṣṇa asked Arjuna "That this is the opportunity to kill him. You kill him immediately." So at that time he had no weapons and he fell down from the chariot, and in that position he was killed by Arjuna by the order of Kṛṣṇa. This is violating the laws.
So you can violate the laws on the order of Kṛṣṇa. You cannot do. This is surrender. When Kṛṣṇa says that "You do this," although it is wrong, you have to do it. There is no consideration.