From owner-freebsd-bugs Mon Sep 25 7:30: 8 2000 Delivered-To: freebsd-bugs@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 4838937B424 for ; Mon, 25 Sep 2000 07:30:03 -0700 (PDT) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id HAA22863; Mon, 25 Sep 2000 07:30:03 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Date: Mon, 25 Sep 2000 07:30:03 -0700 (PDT) Message-Id: <200009251430.HAA22863@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org Cc: From: Dag-Erling Smorgrav Subject: Re: bin/21476: ftp in 4.1-STABLE fails on http:// URLs Reply-To: Dag-Erling Smorgrav Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org The following reply was made to PR bin/21476; it has been noted by GNATS. From: Dag-Erling Smorgrav To: Ruslan Ermilov Cc: bug-followup@FreeBSD.org Subject: Re: bin/21476: ftp in 4.1-STABLE fails on http:// URLs Date: 25 Sep 2000 16:23:08 +0200 Ruslan Ermilov writes: > Forgive me my ignorance but from where of the above it does follow that > the HTTP/1.0 request should include the Host: header and not having it > there should be answered with a 404 reply? For example, Read section 19.6.1.1 of RFC2616. Pay special attention to the part that says "including updates to existing HTTP/1.0 applications" and the part that says "Both clients and servers MUST support the Host request-header". Or just forget the RFC and consider that if ftp(1) does not send a Host: header, it simply will not work with the thousands if not millions of web sites out there that are actually virtual hosts. Regarding the fact that not sending a Host: header sometimes works, and sometimes doesn't, even on servers that host a single site - this is a consequence of Apache striving to be backwards compatible wrt the format of its configuration file (to be more specific, there are two different ways to configure a single-site server, and one of them causes requests without a Host: header to fail) Regarding what you call "fetch(1) propaganda", consider that these and other issues that ftp(1) has trouble with have already been addresses - a long time ago! - in libfetch, and that whoever maintains ftp(1) will now have to solve these problems *again*, in a different code base, for no added gain. Do one thing and do it well! Ftp(1) is very good at interactive or scripted FTP sessions, but sucks at HTTP. Fetch (or rather libfetch) is (or strives to be) very good at simple FTP and HTTP requests, but does not try to support interactive or otherwise complicated FTP sessions. BTW, if you want a list of things libfetch's HTTP code supports but ftp(1) doen't, here goes: - virtual hosts (which is vital these days!) - authentication (including proxy authentication) - redirects (including redirects to FTP documents) - partial fetches - chunked encoding Need I go on? DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message