[技术分享 - ISA 篇] FTP 主动? 被动? 傻傻搞不清楚…

一些时候,我们在通过 ISA 服务器使用 FTP 时 (通常是使用 IE 的 FTP over HTTP), 会发现连接失败。
虽然连接失败的原因可能很多,但如果不通过 ISA 服务器能成功访问 FTP 站点,那问题很有可能与 FTP 的主被动模式有关。

默认情况下,ISA 在处理客户端的 FTP over HTTP 请求时,只会以主动模式与外部 FTP 服务器建立连接,如果要改为 FTP 被动模式,我们需要在 ISA 防火墙服务器上做如下修改:

1. Click Start, click Run, type “regedit”, and then click OK.

2. Locate and double-click the following registry subkey:

HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Services/W3Proxy/Parameters

Note:When you use ISA Server 2004 SP2, you must first create the Parameters key under the W3Proxy key.

3. On the Edit menu, point to New, and then click DWORD Value.

4. Type NonPassiveFTPTransfer as the new value, and then press ENTER

5. Right-click NonPassiveFTPTransfer, and then click Modify.

6. In the Value data box, type 0 (zero), and then click OK.

7. Restart ISA firewall service or restart ISA server.

另外,如果 ISA 外部有防火墙,需要确认外部的防火墙支持的 FTP 模式。

参考
============

James Yi
Microsoft Support Expert