W3C home > Mailing lists > Public > uri@w3.org > February 2004

Re: RFC2396, parsing 'authority' and 'host'

From: Roy T. Fielding <fielding@gbiv.com>
Date: Fri, 13 Feb 2004 00:56:54 -0800
Cc: uri@w3.org
To: Graham Klyne <GK@ninebynine.org>
Message-Id: <922920A2-5E02-11D8-8468-000393753936@gbiv.com>

On Monday, February 2, 2004, at 05:13  AM, Graham Klyne wrote:
> I just found a bug in my URI parsing code that leads me to suggest a 
> minor revision to the syntax in RFC2396bis:  (taken from CVS revision 
> 1.64, from http://cvs.apache.org/viewcvs.cgi/ietf-uri/rev-2002/)
>
> My error was that I overlooked the square brackets in the host 
> production.
>
> Currently:
>
>   authority   = [ userinfo "@" ] host [ ":" port ]
> and
>   host        = [ IPv6reference / IPv4address / hostname ]
>
> My suggestion is for:
>
>   authority   = [ userinfo "@" ] [ host ] [ ":" port ]
> and
>   host        = IPv6reference / IPv4address / hostname
>
> As well as being less easy to overlook the fact that host is optional, 
> I found it (marginally) easier to code this way.

Due to other changes (that allow host to be of zero length), I have
changed it to

    authority   = [ userinfo "@" ] host [ ":" port ]
and
    host        = IP-literal / IPv4address / reg-name

....Roy
Received on Friday, 13 February 2004 03:55:54 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:25:07 UTC