Our masters said: A woman who is alone with her husband, and he is having relations with her, and she sets her eyes upon another at the time of relations — there is no adultery greater than this, as it is said, "The adulterous wife who takes strangers instead of her husband" (Ezekiel 16:32). And is there a woman who commits adultery beneath her own husband? Rather, this is one who encountered a certain man and sets her eyes upon him, while she is having relations with her husband, and her heart is upon him. The king of the Arabs asked Rabbi Akiva: I am black and my wife is black, and she bore me a white son — shall I kill her, for she played the harlot beneath me? He said to him: Do you have images within your house? He said to him: Yes. He said to him: Are the images of your house white or black? He said to him: White. He said to him: When you were occupied with her, she set her eyes upon the images, and bore one like them. And if you wonder about this matter, learn from the flock of Jacob, which came into heat from the rods, as it is said, "And the flock came into heat before the rods" (Genesis 30:39). And the king of the Arabs acknowledged Rabbi Akiva. Thus, every woman who is alone with her husband in holiness — in the end He raises up from her righteous children. So we find with Hannah, who was alone with her husband in holiness; the Holy One, blessed be He, did not withhold her reward, but rather gave her a righteous son like Moses, as it is said, "Though Moses and Samuel stood before Me" (Jeremiah 15:1), and it says, "Moses and Aaron among His priests, and Samuel among those who call on His name" (Psalms 99:6). And so Hannah said, "For this child I prayed, and the LORD has granted me my petition" (1 Samuel 1:27). Why? Because he was sown in holiness. The Holy One, blessed be He, said: In this world I have abhorred all the nations, because they are of impure seed, and I have chosen you, for you are of true seed, as it is said, "And I planted you a choice vine, wholly of true seed" (Jeremiah 2:21); and it is written, "The LORD your God has chosen you" (Deuteronomy 7:6). And even in the time to come I will choose none but you, for you are a holy seed, as it is said, "They shall not labor in vain, nor bear children for terror, for they are the seed blessed of the LORD" (Isaiah 65:23).
Rabbi Akiva and the King of Arabia on the White Son
Midrash Tanchuma Buber, Nasso 13:1
אמרו רבותינו אשה שהוא מתייחדת עם בעלה, והוא משמש עמה, והיא נותנת עיניה באחר בשעת תשמיש, אין לה ניאוף גדול מזה, שנאמר האשה המנאפת תחת אישה [תקח את זרים] (יחזקאל טז לב), וכי יש אשה שמנאפת תחת בעלה, אלא זו שפגעה באיש אחד, ונותנת עיניה בו, והיא משמשת עם בעלה, ולבה עליו. שאל מלך הערביים את ר' עקיבא, אני כושי ואשתי כושית, וילדה לי בן לבן, אני הורגה שזינתה תחתי, א"ל יש לך צורות בתוך ביתך, א"ל הן, א"ל צורות ביתך לבנות או שחורות, א"ל לבנות, א"ל כשהיית עסוק עמה, נתנה עיניה בצורות, וילדה כיוצא בהם, ואם תמיה אתה על הדבר, למוד מצאנו של יעקב מן המקלות היו מתייחמות, שנאמר ויחמו הצאן אל המקלות וגו' (בראשית ל לט), והודה מלך ערביים לר' עקיבא. הוי כל אשה שמתייחדת עם בעלה בקדושה, סוף מעמיד ממנה בנים צדיקים, שכן מצינו בחנה, שנתייחדה עם בעלה בקדושה, לא קיפח הקב"ה שכרה, אלא נתן לה בן צדיק כמשה, שנאמר אם יעמד משה ושמואל לפני (ירמיה טו א), ואומר משה ואהרן בכהניו ושמואל בקוראי שמו (תהלים צט ו), וכן אמרה חנה אל הנער הזה התפללתי ויתן ה' לי את שאלתי (ש"א א כז), למה שנזרע בקדושה, אמר הקב"ה בעולם הזה כל האומות תיעבתי אותם על שהם מזרע הטומאה, ובחרתי בכם שאתם מזרע אמת, שנאמר ואנכי נטעתיך שורק (כולו) [כלה] זרע אמת (ירמיה ב כא), וכתיב בך כחר ה' אלהיך (דברי ז ו), ואף לעתיד לבא איני בוחר אלא בכם שאתם זרע קודש, שנאמר לא יגעו לריק ולא ילדו לבהלה [כי זרע ברוכי ה' המה] (ישעיה סה כג).