Citing the Koran, the Islamic State scholars wrote that saving a Muslim from "death and deterioration is an Islamic legal duty."
But the document notes that Islamic jurists have "permitted, when necessary, the killing of the infidel combatant or the apostate should one need to consume their flesh for the purpose of saving his own life." Islamic scholar Imam al-Nawawi, according to the document, wrote about the "legitmacy of killing the infidel fighters and apostates and eating them."
The Islamic State scholars argue that "If the jurists had permitted, when necessary, the consumption of human flesh as a means counter to death or harm, then it is even more appropriate to transplant of organs from the apostate to the Muslim to save the life of the latter. This is especially true because it was ruled that the apostate's life and organs are not protected. On the contrary, the apostate's life and organs don't have to be respected and can be taken with impunity." LINK