Mishkat al-Masabih 1138
وَعَنْ أَبِي هُرَيْرَةَ رَضِيَ اللَّهُ عَنْهُ قَالَ: قَالَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ: لَا تُبَادِرُوا الْإِمَامَ إِذَا كَبَّرَ فكبروا وَإِذا قَالَ: وَلَا الضَّالّين. فَقُولُوا: آمِينَ وَإِذَا رَكَعَ فَارْكَعُوا وَإِذَا قَالَ: سَمِعَ اللَّهُ لِمَنْ حَمِدَهُ فَقُولُوا: اللَّهُمَّ رَبَّنَا لَك الْحَمد إِلَّا أَنَّ الْبُخَارِيَّ لَمْ يَذْكُرْ: وَإِذَا قَالَ: وَلَا الضَّالّين
From Abu Hurayrah, may Allah be pleased with him, who said: The Messenger of Allah ﷺ said: "Do not go ahead of the imam. When he says the takbir, say the takbir; when he says 'nor of those who go astray', say: Amin; when he bows, bow; and when he says 'Samiʿa Allahu liman hamidah', say: 'O Allah, our Lord, to You be praise.'" Except that al-Bukhari did not mention: "when he says 'nor of those who go astray'."