
One is forbidden to recite the Shema in front of a naked man whose sexual organ is in view. One of the sages, Rav Yehuda, expanded this ruling to include even the sexual organ of a gentile. The scholars asked: What innovation is there in Rav Yehuda’s ruling? It is clear that the rule for a gentile’s sexual organ is as the rule for a Jew’s sexual organ?! They were answered: Because one may compare a gentile’s sexual organ to that of an ass, and one is permitted to recite the Shema in front of an ass’s sexual organ. Why do the sages compare a gentile’s organ to that of an ass? The Scriptures had already drawn this comparison: “The flesh of asses is their flesh” (Ezekiel 23). But despite this comparison, one is forbidden to recite in front of a naked gentile, because the a different Scriptural verse reads “And the nakedness of their father they did not see.” (Shem and Yefet took care did not look at the sexual organ of their father Noah, and Noah was considered a gentile.) Thus, the sexual organ of a gentile is considered “nakedness” by the Scriptures, and one is forbidden to recite the Shema in front of it.
(Babylonian Talmud, Tractate Berachot 25b)