Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

So....

In IIS, if you use the in-build FTP you need to combine the FTP host header in the FTP username e.g. www.hello.com|domain/username

So, the FTP program gets its "hook" from the username. However, you can connect to the FTP site using www.hello.com:21 over the FTP port.

Why then, doesnt the FTP service work the same way as the HTTP service?

IIS knows what site to serve back based on the host header after all....

Thanks!

share|improve this question

1 Answer 1

up vote 4 down vote accepted

Virtual hosts is something built into the HTTP protocol (since HTTP version 1.1).

As you probably know, virtual hosts allow the HTTP server to redirect different requests on the same IP and port to different directories or web applications. Your browser actually sends the name of the website it is trying to connect to along with the request for a document.

Most internet protocols don't work this way. Usually a separate IP address or port number is required if you want to serve up something different. Also, usually the server expects you know it's name, since you just connected to it.

Therefore, the FTP protocol doesn't support virtual hosts, because FTP clients don't explicitly tell the server which site they were trying to access. It may come as a surprise, but the SSL protocol used in HTTPS doesn't support virtual hosts either - you need a separate IP address (or port) for each different SSL certificate you install.

share|improve this answer
    
perfect answer, thanks –  Keeno Mar 8 '11 at 10:43

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.