Project

General

Profile

Actions

Feature #491

closed

Request with empty Host header returns error

Added by conny almost 19 years ago. Updated about 16 years ago.

Status:
Wontfix
Priority:
Normal
Category:
core
Target version:
-
ASK QUESTIONS IN Forums:

Description

In case of an HTTP 1.1 request like the following:


GET / HTTP/1.1
Host:

...lighttpd returns error 400 (Bad Request). While the RFC doesn't explicitly say what to do in case of an empty header value, neither does it explicitly forbid an empty value. The only requirement seems to be that the header "key" (Host:) must be there.

Other popular HTTP server programs (read: Apache and IIS) pass on such requests to the "default host" i.e. status 200 just like as if it was a HTTP 1.*0* request (where Host: can be left out altogether).


Files

lighttpd-empty-host-tests.patch (1.53 KB) lighttpd-empty-host-tests.patch New testcases conny, 2006-02-02 23:11
Actions #1

Updated by stbuehler about 16 years ago

  • Status changed from New to Fixed
  • Resolution set to wontfix

an empty header is as good as no header imho. so i think 400 is the right thing. and this is surely what was intended with the rule "need host header".

Actions #2

Updated by stbuehler about 16 years ago

  • Status changed from Fixed to Wontfix
Actions

Also available in: Atom