חז״ל מתארים את ניסיונו של יוסף עם אשת פוטיפר ואת עמידתו; לפי הסוגיה, דמות אביו וזיכרון בית אביו עמדו לנגד עיניו וסייעו לו להתגבר.
״וַתִּתְפְּשֵׂהוּ בְּבִגְדוֹ לֵאמֹר וְגוֹ׳״, בְּאוֹתָהּ שָׁעָה בָּאתָה דְּיוֹקְנוֹ שֶׁל אָבִיו וְנִרְאֲתָה לוֹ בַּחַלּוֹן, אָמַר לוֹ יוֹסֵף! עֲתִידִין אַחֶיךָ שֶׁיִּכָּתְבוּ עַל אַבְנֵי אֵפוֹד וְאַתָּה בֵּינֵיהֶם, רְצוֹנְךָ שֶׁיִּמָּחֶה שִׁמְךָ מִבֵּינֵיהֶם, וְתִקָּרֵא רוֹעֶה זוֹנוֹת? דִּכְתִיב: ״וְרֹעֶה זוֹנוֹת יְאַבֶּד הוֹן״. מִיָּד — ״וַתֵּשֶׁב בְּאֵיתָן קַשְׁתּוֹ״, אָמַר רַבִּי יוֹחָנָן מִשּׁוּם רַבִּי מֵאִיר: שֶׁשָּׁבָה קַשְׁתּוֹ לְאֵיתָנָהּ. ״וַיָּפֹזּוּ זְרוֹעֵי יָדָיו״ — נָעַץ יָדָיו בַּקַּרְקַע וְיָצְאָה שִׁכְבַת זַרְעוֹ מִבֵּין צִיפּוֹרְנֵי יָדָיו. ״מִידֵּי אֲבִיר יַעֲקֹב״, מִי גָּרַם לוֹ שֶׁיֵּחָקֵק עַל אַבְנֵי אֵפוֹד — אֶלָּא אֲבִיר יַעֲקֹב. ״מִשָּׁם רֹעֶה אֶבֶן יִשְׂרָאֵל״, מִשָּׁם זָכָה וְנַעֲשָׂה רוֹעֶה, שֶׁנֶּאֱמַר: ״רוֹעֵה יִשְׂרָאֵל הַאֲזִינָה נֹהֵג כַּצֹּאן יוֹסֵף״.
The verse states: “And she caught him by his garment, saying: Lie with me” (Genesis 39:12). At that moment his father’s image [deyokeno] came and appeared to him in the window. The image said to him: Joseph, the names of your brothers are destined to be written on the stones of the ephod, and you are to be included among them. Do you desire your name to be erased from among them, and to be called an associate [ro’eh] of promiscuous women? As it is written: “But he who keeps company with harlots wastes his riches” (Proverbs 29:3), as he loses his honor, which is more valuable than wealth. Immediately: “And his bow abode [teishev] firm” (Genesis 49:24). Rabbi Yoḥanan says in the name of Rabbi Meir: This means that his bow, i.e., his penis, returned [shava] to its strength, as he overcame his desire. The verse about Joseph continues: “And the arms of his hands were made supple” (Genesis 49:24), meaning that he dug his hands into the ground and his semen was emitted between his fingernails. “By the hands of the Mighty One of Jacob” (Genesis 49:24): Who caused his name to be etched onto the stones of the ephod? It was only the might of Jacob. “From there, from the Shepherd, the Stone of Israel” (Genesis 49:24) means: From there, because of Joseph’s ability to withstand this trial, he merited to become a shepherd [ro’eh] of the Jewish people, as it is stated: “Listen, O Shepherd of Israel, who leads like the flock of Joseph” (Psalms 80:2).