1

Our department is deploying Kaspersky Anti-Virus. As a result of installing on my Windows 7 workstation, active FTP is automatically disabled.

I have modified _vimrc as follows:

let g:netrw_cygwin = 0
let g:netrw_scp_cmd = 
"\"C:\\Windows\\system32\\ftp.exe -s:C:\\Users\\Cnorton.Arlington1\\vim_ftp.txt "

vim_ftp.txt contains this:

quote PASV

After that, I'm still getting this error:

PORT/EPRT (Active Mode/Extended Active Mode) is not supported. Use PASV/EPSV instead of this

How can I configure ftp to use passive, so I don't get this error?

Incidentally, I have version 7 vim (gvim), but a beta version, running on CentOS. The system is the same remote system I'm trying to reach from my Windows system. The ftp command on that system completes without error. I don't know if that's because it's an ftp command on the same host.

Edit:

OK. I understand not to use the default Windows ftp.exe. So, this is how I'm trying to configure VanDyke's command line version of SecureFx, called sfxcl:

I've made one more modification using sfxcl,

let g:netrw_cygwin = 0
let g:netrw_scp_cmd = "\"C:\\Program Files\\VanDyke Software\\Clients\\sfxcl.exe\" "

and it works on the command line, but not in Vim. I get the same active message, so I believe I'm screwing up something in Vim. I just cannot figure out what that is.

3
  • 1
    I'd say post the contents fo the vim_ftp.txt file as an edit to your answer so we can see what it contains but asterisk out to mask anything sensitive. Feb 1, 2016 at 23:36
  • Correct, show us a complete vim_ftp.txt. Feb 2, 2016 at 6:54
  • @MartinPrikryl I did show you the complete vim_ftp.txt. I only put one command in it. I've got VanDyke's command line SecureFX sfxcl, but I can't get that to work either. I'm editing _gvimrc instead of _vimrc. Maybe that's the problem. Feb 2, 2016 at 13:52

1 Answer 1

2

The Windows FTP command-line client (ftp.exe) does not support the passive mode, on any version of Windows. It makes it pretty useless nowadays due to ubiquitous firewalls and NATs.

Using the quote pasv won't help. It switches only the server to the passive mode, but not the client.


Use any other Windows FTP command-line client instead. Most other support passive mode.

For example WinSCP defaults to the passive mode and there's a guide available for converting Windows FTP script to WinSCP script.

We can help you with that, if you show us the contents of the vim_ftp.txt.

(I'm the author of WinSCP)

2
  • @MartinPrikyl I've edited the OP. I'm hoping to get any ftp client working. Given I've paid for SecureFX and get it's command line version, I'd love to get that working, too. Feb 2, 2016 at 15:06
  • I'm not too familiar with Vim, so I cannot help you further unfortunately. Feb 3, 2016 at 6:53

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .