The Prophet (peace and blessings be upon him) said: "No man should lie with another man, nor a woman with another woman, except a child or a father." The narrator said: Then he mentioned a third (exception), but I forgot it.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب النكاح / 13565