Shahīd as a term of Islamic religious literature is one who spends his
life in the struggle of uplifting the word of God and even sacrifices his life
for this cause. Obviously this person must be obeying all the religious
injunctions without a single exception. We cannot testify that such and such a
person attained to the status of Shahīd even when he died in the battlefield
fighting against the enemies of God, since no body can reveal true motives.
We Muslims commonly become sentimental and don’t turn to our religious sources
to see what they have to say on this matter. Take for instance the case of the
person you have referred to: Ghāzī ‘Ilmuddin. He was prompted to kill somebody
who had passed sacrilegious remarks for the Prophet (sws). Had he tried to
consult the law he would have turned to the authorities. Islamic law does not
allow someone to take the law in his hands and execute anybody who he deems to
be wrong. Whether an Islamic state would have given him the death sentence or
not is another matter. But the fact remains that no individual has the authority
to take the life of another human being.