Forcing IPv4 with SFTP

Bob Proulx bob at proulx.com
Thu Sep 20 06:31:18 EST 2007


Chris Rapier wrote:
> I'm wondering if I'm missing something. With ssh and scp you can force 
> the use of IPv4 with the -4 option. This doesn't seem to be an option or 
> sftp. Is this by design or oversight?

Use the long option name.  All of the options listed in ssh_config(5)
are available this way.

     AddressFamily
             Specifies which address family to use when connecting.  Valid
             arguments are "any", "inet" (Use IPv4 only) or "inet6" (Use IPv6
             only.)

For IPv4 only you would use:

  sftp -oAddressFamily=inet example.com

Bob


More information about the openssh-unix-dev mailing list