Type this into the Terminal:
which sftp
If the result were /usr/bin/sftp
, means you are using the macOS built-in SFTP version that is out of date compared two the GNU version. More details here.
You could install the Homebrew version — which is the GNU version — instead
brew install openssh
And list the openssh
install path:
brew list openssh
Tou would see some binary here for example:
/usr/local/Cellar/openssh/8.4p1_2/.bottle/etc/ (12 files)
/usr/local/Cellar/openssh/8.4p1_2/bin/scp
/usr/local/Cellar/openssh/8.4p1_2/bin/sftp
/usr/local/Cellar/openssh/8.4p1_2/bin/slogin
/usr/local/Cellar/openssh/8.4p1_2/bin/ssh
/usr/local/Cellar/openssh/8.4p1_2/bin/ssh-add
/usr/local/Cellar/openssh/8.4p1_2/bin/ssh-agent
/usr/local/Cellar/openssh/8.4p1_2/bin/ssh-keygen
/usr/local/Cellar/openssh/8.4p1_2/bin/ssh-keyscan
/usr/local/Cellar/openssh/8.4p1_2/libexec/ (4 files)
/usr/local/Cellar/openssh/8.4p1_2/sbin/sshd
/usr/local/Cellar/openssh/8.4p1_2/share/man/ (15 files)
Now type:
which sftp
the result would be /usr/local/bin/sftp
,which is a soft link of /usr/local/Cellar/openssh/8.4p1_2/bin/sftp
Then try the Homebrew version of SFTP and enjoy it!