This week's book giveaway is in the OCAJP forum.
We're giving away four copies of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) and have Khalid A Mughal & Rolf W Rasmussen on-line!
See this thread for details.
Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

FTP v/s HTTP, which one is better?

 
Ajay Kamble
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello All,

I wish to know differences (advantages/disadvantages) between HTTP and FTP protocols and why would anyone prefer one over other.

To make question simple, imagine that a website is offering download of its products over HTTP. Why would its customers prefer FTP download (what might be the advantages, can we write a script, can we pause-resume it)?

1. For example, if someone is using mainframe machine then he needs FTP download. This can be one reason.

Could you all please help me by appending any points that you can think of?

 
Joe Ess
Bartender
Posts: 9312
10
Linux Mac OS X Windows
 
Ajay Kamble
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have already tried Google Search. Rather than just knowing differences (definitions etc.), what I want to know is in which scenarios you need FTP or you would prefer FTP over HTTP.

Please let me know if you can suggest anything.
 
Dan Pyopyo
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
no sure if I'm correct.

In my understanding,
you can use https for secure http.
but for ftp , no secure for it.

and for ftp , one the client downloads a file from ftp server.
he/she can see the whole directory of the ftp folder.
then he/she may access other files you don't plan to disclose to s/he
 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dan Pyopyo wrote:but for ftp , no secure for it.

SFTP (FTP over SSH) is in widespread use.

then he/she may access other files you don't plan to disclose to s/he

FTP is based on user accounts, so fine-grained access control is possible. That's not a distinguishing characteristic to HTTP (which also supports authentication). It's true that HTTP has no "view directory" functionality (although that can be generally be enabled on the server), but that's not a proper security mechanism, as it amounts to security by obscurity.
 
Ajay Kamble
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Still I dont have what I was looking for .

If you have both HTTP download and FTP download as option in what cases you'll prefer FTP,

I can think 2 cases,

1. If you are downloading on mainframe
2. Using FTP you can write a script and then schedule it to run per month, is this right?

Any additional cases you can think?

Regards
-Ajay
 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1. If you are downloading on mainframe

Maybe I'm missing what you mean by this, but I think all mainframes could serve both FTP and HTTP, so that's not much of a difference.

2. Using FTP you can write a script and then schedule it to run per month, is this right?

Sure you can, but you can do the same for HTTP.

I think I'd base it on what level of authentication is required. Setting up multiple user accounts with their respective permissions is likely to be more of a hassle for HTTP than FTP. If, on the other hand, this is publicly available stuff with no authentication, I'd go with HTTP.
 
Ajay Kamble
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually, I want to think from client point of view, Not as a server side.

So for example, I am client and I want to download regularly from a site, then why would I prefer FTP?

Mainframe can server both FTP and HTTP, but if I am downloading on Mainframe then I have to use FTP (not sure on this one).
 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
but if I am downloading on Mainframe then I have to use FTP

Why? Any server *can* offer both; whether it actually does, is, of course, a different matter. But that isn't a principal limitation.
 
Ajay Kamble
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am particularly referring to IBM OS/390 and z/OS.

Do you mean it is possible to browse normal HTTP sites from these servers and download over HTTP (consider downloading from sourceforge.net)?
 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Browse *from* those servers? You mean, have a browser running on those OSes? I have no idea; why would you want to do that? But I'm certain that both HTTP and FTP servers are available for them.
 
Ajay Kamble
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That is what I am trying to know ,
In which cases you'll prefer FTP download.

1. When I want to download *ON* mainframe machine (not from mainframe server) then I'll use FTP as these servers wont have browsers to browse applications and download required files.

I was hoping to find out more such scenarios where FTP is favorable. This was my question. One case that I can think of is listed above.
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24212
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There are some very common and capable command-line HTTP tools like wget and curl, either of which you can use to download a file under script control.

But I'm not sure what the heck we're talking about either. As Ulf was saying, authentication differs between the two; another difference is that traditional FTP can two separate connections, one for commands and one for data, so it can be a little more efficient for complex scenarios involving the transfer of many files.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic