The hadith was traced back to the Prophet ﷺ, who said, "Whoever kills himself with something will be punished with it. Whoever testifies against a Muslim," or he said, "a believer, accusing him of disbelief, it is as though he killed him. Whoever curses him, it is as though he killed him. Whoever swears falsely by a religion other than Islam, he is as he has sworn."
حدثنا عبد الرزاق حدثنا معمر عن أيوب عن أبي قلابة
رفع الحديث إلى النبي ﷺ قال من قتل نفسه بشيء عذب به ومن شهد على مسلم أو قال مؤمن بكفر فهو كقتله ومن لعنه فهو كقتله ومن حلف على ملة غير الإسلام كاذبا فهو كما حلف