A man asked Ali, "Did the Messenger of Allah ﷺ confide anything to you privately, apart from the people?"Ali grew angry until his face turned red and replied, "He did not confide anything to me privately apart from the people, except that he spoke to me of four matters while he and I were in the house."The man asked, "What were they, Commander of the Faithful?"Ali said, "He said, 'Allah curses the one who curses his father. Allah curses the one who slaughters for other than Allah. Allah curses the one who shelters a criminal innovator. And Allah curses the one who alters the boundary markers of the land.'"
أخبرنا قتيبة قال حدثنا يحيى وهو ابن زكريا بن أبي زائدة عن ابن حيان يعني منصورا
سأل رجل عليا هل كان رسول الله ﷺ يسر إليك بشيء دون الناس فغضب علي حتى احمر وجهه وقال ما كان يسر إلي شيئا دون الناس غير أنه حدثني بأربع كلمات وأنا وهو في البيت فقال لعن الله من لعن والده ولعن الله من ذبح لغير الله ولعن الله من آوى محدثا ولعن الله من غير منار الأرض
Muslim reported it in the chapter on Sacrifices, under the section on the prohibition of slaughtering for anyone other than Allah the Exalted and the curse upon whoever does so, hadith no. 1978, from the hadith of Mansur bin Hayan through this same chain. It is also found in Al-Kubra, hadith no. 4511.