与cfftp安全连接 - 哪个端口?

时间:2018-04-11 18:28:02

标签: coldfusion ftp

我正在使用Coldfusion cfftp标记建立与FTP服务器的安全连接:

<cfftp action = "open"
  username = "username"
  connection = "myConnection"
  password = "password"
  fingerprint = "xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx"
  server = "xxx.xxx.xx.xx"
  secure = "yes">

这成功连接;我可以在ftp服务器上查看和下载文件。我正在试图找出它连接的端口。文档说默认情况下cfftp标记连接到端口21,因此它看起来像是连接到端口21.我可以指定port = 21或port = 22,无论哪种方式它仍然可以正常工作。

我发现令人困惑的是当我使用ftp客户端(Bitvise SSH客户端)手动建立相同的连接时。在Bitvise中,我输入与cfftp标签中相同的服务器IP地址,相同的用户名和相同的密码。但是,我必须输入“22”作为连接成功的端口。如果我输入“21”作为端口,我会收到一条消息,说连接失败。连接失败的文本如下:

14:13:29.767 Current date: 2018-04-11
14:13:29.767 Bitvise SSH Client 7.29, a fully featured SSH client for Windows.
Copyright (C) 2000-2017 by Bitvise Limited.
14:13:29.767 Visit www.bitvise.com for latest information about our SSH software.
14:13:29.767 Run 'BvSsh -help' to learn about supported command-line parameters.
14:13:29.767 Cryptographic provider: Windows CNG (x86) with additions
14:13:29.953 Loading default profile.
14:14:26.599 Started a new SSH2 session.
14:14:26.625 Connecting to SSH2 server xxx.xxx.xx.xx:21.
14:14:47.827 Connecton failed. FlowSocketConnector: Failed to connect to target address. Windows error 10060: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.
14:14:47.864 The SSH2 session has been terminated.

所以我不清楚cfftp标签发生了什么(我可以将端口指定为21或22,无论哪种方式都是成功的安全连接),与Bitvise客户端发生的情况相比, port必须指定为22,否则连接失败。

看起来Bitvise必然会尝试建立SSH2会话。这是cfftp标签必须要做的,当安全=是吗?

0 个答案:

没有答案