Jami` at-Tirmidhi Book 43, Hadith 68
about his grandfather Jarhad, he said: "The Prophet (ﷺ) passed by Jarhad in the Masjid and his thigh was exposed, so he said: 'Indeed the thigh is 'Awrah.'"
from his father, from his grandfather, who said: "I said: 'O Prophet of Allah! Regarding our 'Awrah, what of it must we cover and what of it may we leave?' He said: 'Protect your 'Awrah except from your wife or what your right hand possesses.' He said: "I said: 'O Messenger of Allah! What about when some people are with others?' He said: 'If you are able to not let anyone see it then do not let them see it.'" He said: "I said: 'O Prophet of Allah! What about when one of us is alone?' He said: 'Allah is more deserving of being shy from Him than the people.'"
from his father, from the Prophet (ﷺ) who said: "The thigh is 'Awrah."