开发者

command line sftp: email address as username

I need to connect to an sftp server from Mac OS X and the username given is an email address (someone@example.com)

So my connection string looks like:

sftp someone@example.com@ftp.example.com

The connection does not accept the password so I assume it is confused by the double "@".

I tried to escape the first "@" with "\@" But that crashed the sftp server and would only ha开发者_运维百科ve an effect for the shell I'd think.

What is the proper way to escape this in order to get it to work.

Unfortunately the sftp command on Mac OS X does not allow me an option for interactive username prompt.


Add an entry for the host in ~/.ssh/config that has the desired name.

Host stupidadminhost
    HostName ssh.example.com
    User somewhere@outthere.com

Then just SFTP to stupidadminhost instead, with no given username.


sftp -o User=someone@example.com ftp.example.com


As a workaround I use YummyFTP. It bypasses a lot of the complicated options and gives you a visual interface. It has been a time saver for me with lots of different sites to interact with.


sftp "someone@example.com"@ftp.example.com

This does the trick too.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜