Usually, not discriminating based on Syntax and choice of language,
Both Metasploit and Impacket works similar when using PSExec with or without Pass The Hash.
We explicitly mention if we are using clear text password or the hash, and then boom, SHELL: AND rest is easy.
This is the video about what exactly happens behind the scenes.
#PSExec #PassTheHash #Lateral_Movement