عَنْ عَبْدِ اللَّهِ بْنِ عَمْرٍو رَضِيَ اللَّهُ عَنْهُمَا قَالَ جَاءَ إِلَى رَسُولِ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَآلِهِ وَسَلَّمَ رَجُلٌ فَقَالَ يَا رَسُولَ اللَّهِ ائْذَنْ لِي أَنْ أَخْتَصِيَ فَقَالَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَآلِهِ وَسَلَّمَ خِصَاءُ أُمَّتِي الصِّيَامُ وَالْقِيَامُ
Narrated from Sayyiduna Abdullah bin Amr (may Allah be pleased with them both) that a man came to the Prophet Muhammad (peace and blessings be upon him) and said: O Messenger of Allah! Permit me to be castrated. The Prophet (peace and blessings be upon him) said: The way of castration for my Ummah is to fast and to stand in prayer at night.