Access FTP via HTTP?

蹲街弑〆低调 提交于 2021-02-18 12:55:59

问题


We have an external secure FTP server that we want to access through HTTPS (our infrastructure does not support FTPs). I know that's possible but I don't know how. I'm looking for something like this: ftp://ftp.mozilla.org/pub/mozilla.org/zz http://ftp.mozilla.org/pub/mozilla.org/zz

Thanks!


回答1:


To add some clarification: FTP and HTTP are, as SLaks said, two entirely different things. The links you have posted use two separate protocols. One if ftp, and one is http. You appear to be getting confused by the second link because it still has ftp in it. What is happening there is that "ftp.mozilla.org" is the domain name of that server. the pages themselves look similar because there is not actual page you are referencing (you are visiting the directory itself) and there is no default page specified in that directory (for example, no index.html).

The default behavior in this case is to simply list the directory contents, which is pretty much what the ftp protocol does anyway.

So:

You will need to either install a web server program (not an ftp server program!) on the ftp server (the physical box) and let users download files using the http(s) protocol, or you will as SLaks suggested need to create your own proxy (or find one that exists) that will receive commands from the http protocol and transform them into the equivalent ftp commands, which are then sent to the ftp server.

Personally, I recommend the former, as it is less complicated.




回答2:


FTP and HTTP are two different protocols that have nothing to do with each-other.

You need to run an HTTP server.

You can either run an HTTP server that exposes the same files (like Mozilla does), or write an HTTP proxy for the FTP server.




回答3:


Sounds like you are looking for a web-based FTP client. http://www.net2ftp.com/ is a good place to start, but you will have to configure the tunnel appropriately within your network. A solution like net2ftp will tunnel traffic to and from the server as HTTP, then running local scripts.

You will also want to remember that there are other file protocols your network administrator can open up aside from SFTP/FTP. Ask them about a private SSH key alternative, which would avoid a public-facing web-based FTP server/client solution.



来源:https://stackoverflow.com/questions/17554435/access-ftp-via-http

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!