Hand Shake With Na Mehram.
A prophet or a sahabi not doing something doesn’t prove or disprove it’s permissibility, especially in the case of cultural norms that vary in time and space. We should know in principle what things have been declared as haram, what reasons have been given for such, and make ijtihad using our God given faculty of intellect in application of those principles to anything new. For a detailed discussion on the topic of handshake, please see Discussion 17836