Sayyiduna Zayd bin Thabit (may Allah be pleased with him) narrates that the Prophet (peace and blessings be upon him) forbade praying when the edge of the sun rises or when its edge sets, because it (the sun) rises between the two horns of Shaytan (the narrator is in doubt about one word here).
Ahmad recorded it, and its narrators are the narrators of the Sahih.