Project

General

Profile

Actions

Bug #2143

closed

Numeric tld's

Added by khemael about 15 years ago. Updated almost 9 years ago.

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

Description

Hi. It seems that lighttpd won't handle numeric tlds. Tried with bot numeric+alpha eand pure numeric tlds.

Yes, numeric tlds aren't part of actual ICANN's TLD's, but anyway, as of ICANN'S applicant book (Draft V3 of october 2009), numeric and pure numeric TLD's are not a problem. Pure numeric tlds should however append a non-numeric subdomain in their tld policies if the tld is somewhat between 0-255.
Also, it seems that numerous of numeric and alphanumeric TLD's are in approach for 2010 ICANN gTLD's evaluation. Oh, and we just can't use lighttpd in our company due to these restriction. Sticking with Apache here.


khemael@alpha:~$ dig -t A nsd.geeks.42 +short
88.181.160.249
khemael@alpha:~$ telnet nsd.geeks.42 80
Trying 88.181.160.249...
Connected to nsd.geeks.42.
Escape character is '^]'.
GET / HTTP/1.1
host : www.khemael.net

HTTP/1.1 400 Bad Request
Connection: close
Content-Type: text/html
Content-Length: 349
Date: Thu, 31 Dec 2009 23:14:31 GMT
Server: lighttpd/1.4.19

<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
         "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
 <head>
  <title>400 - Bad Request</title>
 </head>
 <body>
  <h1>400 - Bad Request</h1>
 </body>
</html>
Connection closed by foreign host.
khemael@alpha:~$ telnet nsd.geeks.42 80
Trying 88.181.160.249...
Connected to nsd.geeks.42.
Escape character is '^]'.
GET / HTTP/1.1
host : nsd.geeks.42

HTTP/1.1 400 Bad Request
Connection: close
Content-Type: text/html
Content-Length: 349
Date: Thu, 31 Dec 2009 23:14:49 GMT
Server: lighttpd/1.4.19

<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
         "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
 <head>
  <title>400 - Bad Request</title>
 </head>
 <body>
  <h1>400 - Bad Request</h1>
 </body>
</html>
Connection closed by foreign host.


Files

patch-src-request.c (1.18 KB) patch-src-request.c majinboo, 2010-12-28 15:44

Related issues 1 (0 open1 closed)

Has duplicate Bug #2281: 400 Bad Request when using Numeric TLDsDuplicate2010-12-22Actions

Added by gstrauss almost 9 years ago

Revision b47494d4 (diff)

[config] opts for http header parsing strictness (fixes #551, fixes #1086, fixes #1184, fixes #2143, #2258, #2281, fixes #946, fixes #1330, fixes #602, #1016)

server.http-parseopt-header-strict = "enable"
server.http-parseopt-host-strict = "enable" (implies host-normalize)
server.http-parseopt-host-normalize = "disable"

defaults retain current behavior, which is strict header parsing
and strict host parsing, with enhancement to normalize IPv4 address
and port number strings.

For lighttpd tests, these need to be enabled (and are by default)
For marginally faster HTTP header parsing for benchmarks, disable these.

To allow
- underscores in hostname
- hypen ('-') at beginning of hostname
- all-numeric TLDs
server.http-parseopt-host-strict = "disable"

x-ref:
"lighttpd doesn't allow underscores in host names"
https://redmine.lighttpd.net/issues/551
"hyphen in hostname"
https://redmine.lighttpd.net/issues/1086
"a numeric tld"
https://redmine.lighttpd.net/issues/1184
"Numeric tld's"
https://redmine.lighttpd.net/issues/2143
"Bad Request"
https://redmine.lighttpd.net/issues/2258
"400 Bad Request when using Numeric TLDs"
https://redmine.lighttpd.net/issues/2281

To allow a variety of numerical formats to be converted to IP addresses
server.http-parseopt-host-strict = "disable"
server.http-parseopt-host-normalize = "enable"

x-ref:
"URL encoding leads to "400 - Bad Request""
https://redmine.lighttpd.net/issues/946
"400 Bad Request when using IP's numeric value ("ip2long()")"
https://redmine.lighttpd.net/issues/1330

To allow most 8-bit and 7-bit chars in headers
server.http-parseopt-header-strict = "disable" (not recommended)

x-ref:
"Russian letters not alowed?"
https://redmine.lighttpd.net/issues/602
"header Content-Disposition with russian '?' (CP1251, ascii code 255) causes error"
https://redmine.lighttpd.net/issues/1016

Actions

Also available in: Atom