[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: I-D ACTION:draft-fenner-literal-zone-00.txt



> > > You might already know but <draft-fielding-uri-rfc2396bis-07.txt>
> > > allows %xx notation in host part.

I should also mention that <draft-fielding-uri-rfc2396bis-07.txt> does
not allow %xx notation in literal IPv6 address, as follows.

    IP-literal    = "[" ( IPv6address / IPvFuture  ) "]"

    IPvFuture     = "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" )

    IPv6address   =                            6( h16 ":" ) ls32
                  /                       "::" 5( h16 ":" ) ls32
                  / [               h16 ] "::" 4( h16 ":" ) ls32
                  / [ *1( h16 ":" ) h16 ] "::" 3( h16 ":" ) ls32
                  / [ *2( h16 ":" ) h16 ] "::" 2( h16 ":" ) ls32
                  / [ *3( h16 ":" ) h16 ] "::"    h16 ":"   ls32
                  / [ *4( h16 ":" ) h16 ] "::"              ls32
                  / [ *5( h16 ":" ) h16 ] "::"              h16
                  / [ *6( h16 ":" ) h16 ] "::"

      unreserved     = ALPHA / DIGIT / "-" / "." / "_" / "~"
      sub-delims     = "!" / "$" / "&" / "'" / "(" / ")"
                     / "*" / "+" / "," / ";" / "="
      ls32        = ( h16 ":" h16 ) / IPv4address
      h16         = 1*4HEXDIG

Hence, a URI parser should not interpret %xx notation in IP-literal,
if it follows <draft-fielding-uri-rfc2396bis-07.txt>.

Regards,
Noritoshi Demizu


> From: Noritoshi Demizu <demizu@xxxxxxxxxxxxxx>
> To: Brian E Carpenter <brc@xxxxxxxxxxxxxx>
> Cc: ipv6@xxxxxxxx, Margaret Wasserman <margaret@xxxxxxxxxxxxxx>
> Subject: Re: I-D ACTION:draft-fenner-literal-zone-00.txt
> Date: Tue, 07 Dec 2004 22:13:21 +0900 (JST)
>
> > >>No.  As BNF states in RFC 2396, escape by '%' is not allowed for hostport.
> > >>So the implementation should not interpret '%33' as '3' when it appears
> > >>in hostname or IP address, in any cases.
> > >
> > > You might already know but <draft-fielding-uri-rfc2396bis-07.txt>
> > > allows %xx notation in host part.
> >
> > Really?
>
> I believe so.  The following ABNF is extracted from Appendix A of
> <draft-fielding-uri-rfc2396bis-07.txt> (Sep 2004).
>
>     URI           = scheme ":" hier-part [ "?" query ] [ "#" fragment ]
>     hier-part     = "//" authority path-abempty
>                   / path-absolute
>                   / path-rootless
>                   / path-empty
>     authority     = [ userinfo "@" ] host [ ":" port ]
>       host        = IP-literal / IPv4address / reg-name
>       reg-name    = *( unreserved / pct-encoded / sub-delims )
>     pct-encoded   = "%" HEXDIG HEXDIG
>
> <draft-duerst-iri-11.txt> (Nov 2004) also allows %xx notation in host
> part.  The following ABNF is extracted from section 2.2 of it.
>
>       IRI            = scheme ":" ihier-part [ "?" iquery ]
>       ihier-part     = "//" iauthority ipath-abempty
>                      / ipath-absolute
>                      / ipath-rootless
>                      / ipath-empty
>       iauthority     = [ iuserinfo "@" ] ihost [ ":" port ]
>       ihost          = IP-literal / IPv4address / ireg-name
>       ireg-name      = *( iunreserved / pct-encoded / sub-delims )
>       pct-encoded    = "%" HEXDIG HEXDIG
>
> Regards,
> Noritoshi Demizu

--------------------------------------------------------------------
IETF IPv6 working group mailing list
ipv6@xxxxxxxx
Administrative Requests: https://www1.ietf.org/mailman/listinfo/ipv6
--------------------------------------------------------------------